In irb:

f = File.new('numbers.txt')
=> #<File:numbers.txt>

f.each {|line| puts line}
123
456
789
=> #<File:numbers.txt>

f.each {|line| puts line}
=> #<File:numbers.txt>

Why doesn't the second f.each work?

-- 
Posted via http://www.ruby-forum.com/.