From: Florian Gilcher Date: 2009-11-29T13:06:41+09:00 Subject: Re: Just found a round problem -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 On Nov 29, 2009, at 12:06 AM, Ruby Newbee wrote: > irb(main):026:0> 10.499999999999999.round > => 10 > irb(main):027:0> 10.4999999999999999.round > => 11 > > > Does this happen due to the float problem in any languages including > ruby? > Thanks. Thats IEEE 754 float behaviour, yes. python behaves exactly the same. - -- Florian Gilcher smtp: flo@andersground.net jabber: Skade@jabber.ccc.de gpg: 533148E2 -----BEGIN PGP SIGNATURE----- Version: GnuPG/MacGPG2 v2.0.12 (Darwin) iEYEARECAAYFAksR80wACgkQyLKU2FMxSOLkpwCdFwIj6FfsGK3+ZFFVLPQV0XwJ Xa8AnAp6o5sxct7fsDrJUWUkIJ0QmB19 =bERM -----END PGP SIGNATURE-----