On 12/17/06, Devin Mullins <twifkak / comcast.net> wrote:
> Ah, but to get access to the 2nd nil, yours requires an external
> counter*, whereas select_view can go both ways (potentially):
>    ary.select{|x| x % 2 == 0}.map! {|x| x / 2}
>
> (I'd provide a patch, but it's early.)
> Devin
>
> *or a combination of enum_for(:each_with_index) and a non-destructive
> version of map_if defined in Enumerable.

Yeah, if you specifically require the nth element returned by select,
then an external cursor is the way to go. I just cannot think of any
case where you would.

martin