Looking for the greatest negative float value

Mel Wilson mwilson at the-wire.com
Thu Jun 12 17:15:50 CEST 2003


In article <ad052e5c.0306112101.4e9f123 at posting.google.com>,
danb_83 at yahoo.com (Dan Bishop) wrote:
>mwilson at the-wire.com (Mel Wilson) wrote in message news:<Yr55+ks/KTSM089yn at the-wire.com>...
>> In article <bc7lvb$gm3$1 at news-reader12.wanadoo.fr>,
>> "Gilles Lenfant" <glenfant at NOSPAM.bigfoot.com> wrote:
>> >Hi,
>> >
>> >I need the same as...
>> >
>> >import sys
>> >negmaxint = - sys.maxint -1
>> >
>> >... but for float data
>[snip]
>> -1.7976931348623157e+308
>>
>> and that last number seems credible.
>
>Close.  The exact value, per the IEEE 754 standard, is -(2 ** 1024 - 2
>** 972), or -1.7976931348623155e+308.  How did you get a *higher*
>magnitude?

   I didn't get it, it was the code I posted.  Maybe we
should look at repr.

        Regards.        Mel.




More information about the Python-list mailing list