From: "Berger, Daniel" Date: 2005-05-24T06:17:32+09:00 Subject: Re: loop over array with indices > -----Original Message----- > From: Johannes Ahlmann [mailto:softpro@gmx.net] > Sent: Monday, May 23, 2005 3:15 PM > To: ruby-talk ML > Subject: loop over array with indices > > > hi, > > i have the recurring problem that i want to loop over an > array with each/collect/... but (as an afterthought) need the > index of the current element. See Enumerable#each_with_index. Regards, Dan