3.2*2 is 9.6 ... or maybe it isn't?
Tomasz ZieliĆski
tomasz.zielinski at pyconsultant.eu
Thu Jun 25 14:20:13 EDT 2009
On 25 Cze, 20:04, Bojan Sudarevic <bo... at sudarevic.com> wrote:
>
> I wasn't particularly good in math in school and university, but I'm
> pretty sure that 3.2*3 is 9.6.
>
It's not math, it's floating point representation of numbers - and its
limited accuracy.
Type 9.6 and you'll get 9.5999999999999996
--
Tomasz Zielinski
http://pyconsultant.eu
More information about the Python-list
mailing list