printing anomaly

Paul Rubin http
Sun Mar 20 19:52:51 EST 2005


What's the deal with this?

    >>> print 3.2
    3.2
    >>> print [3.2]
    [3.2000000000000002]
    >>> 

Yes, I know that 3.2 isn't an exact binary fraction.  I'm wondering
why it's converted differently depending on whether it's in a list.



More information about the Python-list mailing list