Math errors in python
nospam at here.com
Sun Sep 19 10:16:13 CEST 2004
On Sun, 19 Sep 2004 08:00:03 GMT, Chris S. wrote:
> Sqrt is a fair criticism, but Pi equals 22/7, exactly the form this
> arithmetic is meant for. Any decimal can be represented by a fraction,
> yet not all fractions can be represented by decimals. My point is that
> such simple accuracy should be supported out of the box.
Do you really think Pi equals 22/7 ?
>>> import math
>>> print math.pi
>>> print 22.0/7.0
What do you get on your $20 calculator ?
More information about the Python-list