Floating point number problem...............

Python-lover hemanexp at yahoo.com
Fri May 23 08:07:33 EDT 2003


Hi,    I have a problem in floating point number. I assgined a value, say 1.23456, to a variable. When i printed the variable i got 1.234560000000001 instead of   1.23456. How can i get the original value? Moreover how to have a floating point number that has  only 3 numbers after decimal point even the number has got more digits after the decimal point?  I tried with "round" function but it is rounding the 3rd digit  instead of keeping it as it is.  Thanx.  

---------------------------------
Do you Yahoo!?
The New Yahoo! Search - Faster. Easier. Bingo.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-list/attachments/20030523/1dc53fbc/attachment.html>


More information about the Python-list mailing list