R
Robert Klemme
First I've heard of the 'used to'! When did that change?
I was surprised myself, too:
irb(main):001:0> 1 / 2
=> 0
irb(main):002:0> 1.quo 2
=> 0.5
irb(main):003:0> require 'rational'
=> true
irb(main):004:0> 1 / 2
=> 0
irb(main):005:0> 1.quo 2
=> Rational(1, 2)
irb(main):006:0> RUBY_VERSION
=> "1.8.5"
I believe I remember that "1 / 2" used to return "Rational(1, 2)" with
'rational' loaded. Is my memory wrong here?
Kind regards
robert