From: Navindra Umanee Date: 2005-03-01T14:39:20+09:00 Subject: Re: for vs. each Csaba Henk wrote: > ruby -rbenchmark -e 'n=10**6; [ > proc{ (0...n).each{|x| x} }, > proc{ for x in 0...n; x ;end }, > proc{ n.times{|x| x} } > ].each {|pr| puts Benchmark.measure(&pr) }' I have to say, I often wonder why people post Ruby code in this format. It seems to me -e coupled with multi-line code is terribly inconvenient... unless I'm missing something. Cheers, Navin.