Issue 28285: 35.5 - 29.58 = 5.920000000000002 (it's false !) (original) (raw)
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