On Thu, Aug 22, 2002 at 12:12:30AM +0900, Robert McGovern wrote: > I was just writing an example for the "power of ruby" thread, using ranges. > > I had two calls > > a: (1..78).each {|x| print "#{x}, "} > b: (78..1).each {|y| print "#{y}, "} > > The first worked as expected, it printed 1 to 78 to the screen. > > However the second, simply printed nothing. Am I wrong to expect that a > range can work for both up and down? Yes. > > (Using Ruby 1.6.6 windows installer, on Windows XP) > > Rob See: http://blade.nagaokaut.ac.jp/cgi-bin/scat.rb/ruby/ruby-talk/39324 http://blade.nagaokaut.ac.jp/cgi-bin/scat.rb/ruby/ruby-talk/8993 -Martin