[Tutor] floating point accuracy

Stephen Ng steveng@pop.jaring.my
Wed Aug 6 02:56:02 EDT 2003


Hi!

I am a total newcomer to python so still trying to find out what its all
about.

I tried the following 2/5.0 and received 0.40000000000000002.

The 2 at the end makes me wonder whether this is normal and how accurate
floating point arithmetic is.

Stephen Ng





More information about the Tutor mailing list