View Single Post
Old 10-25-2006, 06:53 PM   PM User | #1
SHY
New Coder

 
Join Date: Apr 2005
Location: Kosice, Slovakia
Posts: 36
Thanks: 2
Thanked 0 Times in 0 Posts
SHY is an unknown quantity at this point
weirdness between windows and linux

a m8 of mine was reading thru the python tutorial and while he was trying out some float numbers formatting, he came to a weird result (note: he is using windowsXP):

Code:
>>> print '%0.50f' % (22.0/7.0)
3.14285714285714280000000000000000000000000000000000
this is what i get on linux:

Code:
>>> print '%0.50f' % (22.0/7.0)
3.14285714285714279370154144999105483293533325195312
how the hell is this possible?
__________________
"Programming is an art form that fights back."
SHY is offline   Reply With Quote