Subject: for vs. each
From: "Fear Dubh" <feardubh spam.spam>
Date: Sun, 27 Feb 2005 20:25:00 +0900
Hello,
Is there a difference between:
for foo in bar do ...
and
bar.each do |foo| ...
or is it just a question of style?
I prefer the look of "for ... do ...",
but I mostly see each in the samples posted by the Ruby
wizards on the NG.
Thanks