extracting hex mant+exp from double?
thinkit
thinkit8 at lycos.com
Sat Jun 9 21:18:15 EDT 2001
python docs say floats are all doubles...which usually (i think always) is the
IEEE spec for 8-byte float. are there any routines out there to extract the
binary mantissa and exponent...or better hexadecimal mantissa and exponent out
of the float? i want to do some statistics but don't want to use decimal. i
know you can access the 8 bytes with struct lib...then do some bit manipulations
to do the trick. has anybody done this already?
More information about the Python-list
mailing list