Numbers in python

Duncan Booth duncan.booth at invalid.invalid
Fri Mar 10 15:51:35 CET 2006


> If I put them in the dictionary as 'THE' = int(0.965) the
> program returns 1.0 and if I put 'THE' = float(0.965) it returns
> 0.96555555549 or something similar. Neither of these are right!

Your system seems to be really screwed. int(0.965) should be 0, and 
float(0.965) should be 0.96499999999999997 or something similar.


More information about the Python-list mailing list