Decimal() instead of float?

Carsten Haese carsten at uniqsys.com
Fri Nov 17 23:00:29 CET 2006


On Fri, 2006-11-17 at 16:51 -0500, Michael B. Trausch wrote:
> [...]
> Let's say that I want to work with the latitude 33.6907570.  In
> Python, that number can not be stored exactly without the aid of
> decimal.Decimal().
> 
> >>> 33.6907570
> 33.690756999999998

You say that like it's Python's fault. Can this number be stored
*exactly* in C?

-Carsten





More information about the Python-list mailing list