Message15183
Python version 2.1 (2.2.1 behaves the same).
Windows 2000 and RH Linux 8.0
This was run on an Intel platform.
>>> v = 7.0 + .1 + .1 + .1 + .1 + .1 + .1 + .1 + .1 + .1
+ .1
>>> v
7.9999999999999964
>>> struct.pack( "f", v )
'\x00\x00\x00A'
>>> struct.pack( ">f", v )
'@\x80\x00\x00'
These two should be the same byte pattern (only
reversed)!
>>> struct.unpack( ">f", '@\x80\x00\x00' )
(4.0,)
!!!!!
|
|
Date |
User |
Action |
Args |
2007-08-23 14:11:58 | admin | link | issue705836 messages |
2007-08-23 14:11:58 | admin | create | |
|