From: Stephen Becker Date: 2010-10-07T07:41:40+09:00 Subject: Re: looping through array starting at i !=0 --0016361e7b9c024aab0491fa7b59 Content-Type: text/plain; charset=ISO-8859-1 @weights[2..-1].each_index{|i| } or @weights.each_index{|i| next if i<2 code } I think the first version makes a new object. Becker On Wed, Oct 6, 2010 at 3:08 PM, John Smith wrote: > Hi everyone, > > I want to loop through this array, but not for every index.. only > indices that are > greater than 2. > > > @weights.each_index do |i| > end > > Ted > -- > Posted via http://www.ruby-forum.com/. > > --0016361e7b9c024aab0491fa7b59--