[Python-ideas] math.inf and math.nan constants

Steven D'Aprano steve at pearwood.info
Thu Jan 8 00:23:05 CET 2015

On Thu, Jan 08, 2015 at 05:58:03AM +1100, Alexander Heger wrote:

> IEEE754 requires that all comparisons with NaN give false, i.e.,

Not quite. "Not equal" comparisons should return true.

NANs should compare unordered and unequal to everything including 


More information about the Python-ideas mailing list