1.1.coerce(1) # [1.0, 1.1]: coerce Fixnum to Floatrequire "rational" # Use Rational numbersr = Rational(1,3) # One third as a Rational numberr.coerce(2) # [Rational(2,1), Rational(1,3)]: Fixnum to Rational