From: Jeff Mitchell Date: 2004-05-26T17:13:16+09:00 Subject: Re: [RCR] Numeric#of --- Simon Strandgaard wrote: > Martin DeMello wrote: > > Simon Strandgaard wrote: > > > Simon Strandgaard wrote: > > > [snip] > > > > Your 'of' is a mix between times and map. Wouldn't it be better to > > > > name it 'times_map' ? > > > > > > > > > > Even simpler.. it would make sense to me if it were just named 'maps' > > > > > > a, b, c = 3.maps {|n| -n} > > > # a=0, b=-1, c=-2 > > > > Or even just map (there's no Numeric#map) - I don't like that either > > [ruby-talk:62177] but I can't think of anything I like better. > > Agree, Numeric.map would be perfect. I think we should bring in all Enumerable rather than implementing just #map. Please see [ruby-talk:101426]. a, b, c = 3.enum.map {|n| -n} __________________________________ Do you Yahoo!? Friends. Fun. Try the all-new Yahoo! Messenger. http://messenger.yahoo.com/