Ruby读写文件
1. 读取
file=File.new('D:\\test\\ruby.txt','w')file.puts "first line"file.puts "second line"file.close