From: Martin Weber Date: 2003-01-17T08:26:19+09:00 Subject: Re: Ruby advocacy in sigs On Fri, Jan 17, 2003 at 08:08:46AM +0900, Tim Bates wrote: > On Fri, 17 Jan 2003 05:32 am, Travis Whitton wrote: > > here are some examples of Ruby's object oriented nature > > 9.times {|num| puts num} # 0123456789 > > That one's wrong. Anyone who knew Ruby and actually read it would spot it, but > I though I'd point it out incase anyone blindly copied-and-pasted. > > 9.times {|num| puts num} # 999999999 > 0.upto(9) {|num| puts num} # 0123456789 Anyone who knews ruby would spot it, uh huh. $ irb --simple-prompt >> 9.times {|n| print n} 012345678=> 9 >> 9.times {|n| puts n} 0 1 2 3 4 5 6 7 8 => 9 >> ^D Pity I don't know ruby. Good irb does :-) -Martin