Is round() broken?

Skip Montanaro skip at pobox.com
Wed Oct 31 16:05:25 EST 2001


    Joseph> So, what this is saying.. is that rounding to 1 decimal point
    Joseph> works... but anything beyond that is broken?

Nothing's broken.  Floating point representation is simply inexact.  Check
out the appendix on floating point arithmetic in the development version of
the Python tutorial:

    http://python.sourceforge.net/devel-docs/tut/node14.html

-- 
Skip Montanaro (skip at pobox.com)
http://www.mojam.com/
http://www.musi-cal.com/




More information about the Python-list mailing list