Anonymous user
File input/output: Difference between revisions
→[[Ruby]]
No edit summary |
|||
Line 329:
begin
#both files are closed automatically at the end of their attached blocks
of = File.new("output.txt", "w")▼
File.
of.puts line▼
inputf.each_line do | line |
end
end
end
rescue Exception => e
$stderr.puts "Exception raised: #{e}"
end
|