Rob Biedenharn wrote:

> irb> class Integer
>         def countdown
>           self.downto(1){|i|yield i}
>         end
>       end
> => nil
> irb> 35.countdown {|i| print i, ' '}; puts "Boom!"
> 35 34 33 32 31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16 15 14 13
> 12 11 10 9 8 7 6 5 4 3 2 1 Boom!

yup, that's similar to what i was looking for.  And 35.times doesn't 
have any mechanism to count down i guess, not like

for i = 35 to 1 step -1
  do something
next

-- 
Posted via http://www.ruby-forum.com/.