File input/output: Difference between revisions
→{{header|Oforth}}
(Nimrod -> Nim) |
|||
Line 1,743:
end
</lang>
=={{header|Oforth}}==
<lang Oforth>func: fcopy(in, out)
{
| f g |
File new(in) dup openMode(File.READ, File.BINARY) ->f
File new(out) dup openMode(File.WRITE, File.BINARY) ->g
while(f >> dup notNull) [ g addChar ] drop
f close
g close
}</lang>
Usage :
<lang Oforth>fcopy("input.txt", "output.txt")</lang>
=={{header|OpenEdge/Progress}}==
|