From: "David A. Black" Date: 2004-09-21T19:50:38+09:00 Subject: Re: Array#index block and rdetect Hi -- On Tue, 21 Sep 2004, Randy W. Sims wrote: > David A. Black wrote: > > > Enumerable: > > > > each_with_counter # "dumb" counters, for every enumerable, > > each_counter # strictly based on incrementing through > > # #each > > I'm not sure I understand the justification for these. It's simple > enough to provide your own counter if needed: > > counter = 0 > var.each { |item| counter += 1; puts counter } > > A little less candy, but same effect. I'm not sure I see the benefit. each_with_counter is just a rename of each_with_index, which already exists. David -- David A. Black dblack@wobblini.net