From: Yukihiro Matsumoto Date: 2004-09-20T00:10:14+09:00 Subject: Re: Array#index block and rdetect Hi, In message "Re: Array#index block and rdetect" on Sun, 19 Sep 2004 23:20:08 +0900, "trans. (T. Onoma)" writes: |> > Array#index optionally take a block like Enumerable#detect does. |> > |> > ['a','b','c'].index{|e| e == 'b'} # => 1 |> > ['a','b','c'].index{|e| e == 'c'} # => 2 |> > ['a','a','a'].index{|e| e == 'a'} # => 0 |> > ['a','a','a'].index{|e| e == 'b'} # => nil | |But this Array#index {block) is acceptable, yes? Along with assoc and rassoc. I will consider this idea. matz.