From: Stephen White Date: 2001-07-13T16:19:21+09:00 Subject: [ruby-talk:17774] Re: YART (Yet Another Ruby Talk) On Fri, 13 Jul 2001, Martin DeMello wrote: > From a newbie perspective, > > array.collect! { | elem | elem += x } > > is a misleading piece of code, since you're using += for its return value > rather than its side effect. That would have gotten me. I had to read it again to be sure what it was doing... array.collect! {|elem| elem + x } would be clearer. -- spwhite@chariot.net.au