RosettaCodeData/Task/File-input-output/IDL/file-input-output.idl

13 lines
232 B
Text
Raw Permalink Normal View History

2013-04-10 21:29:02 -07:00
; open two LUNs
openw,unit1,'output.txt,/get
openr,unit2,'input.txt',/get
; how many bytes to read
fs = fstat(unit2)
; make buffer
buff = bytarr(fs.size)
; transfer content
readu,unit2,buff
writeu,unit1,buff
; that's all
close,/all