This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author Hogren
Recipients Hogren
Date 2016-09-27.10:13:54
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1474971235.03.0.505577287103.issue28285@psf.upfronthosting.co.za>
In-reply-to
Content
I was using python as calculator when I enter :
35.5 - 29.58

I am surprising when python give me a result with many decimals:
5.920000000000002

I tried to change one number :
35.5 - 29.57
The result is correct : 5.93

The error is present again when I tried to inverse numbers (29.57-35.5).

The error is again present when I tried to use 35.50 in place of 35.5.



I tested on python 2.7 and 3.4, compiled with gcc 4.9.3, on Gentoo.


Thanks for all who contribute to this good project which is Python !

Hogren
History
Date User Action Args
2016-09-27 10:13:55Hogrensetrecipients: + Hogren
2016-09-27 10:13:55Hogrensetmessageid: <1474971235.03.0.505577287103.issue28285@psf.upfronthosting.co.za>
2016-09-27 10:13:54Hogrenlinkissue28285 messages
2016-09-27 10:13:54Hogrencreate