Steven D'Aprano writes:
> As usual though, NANs are unintuitive:
>
> >>> d = {float('nan'): 1}
> >>> d[float('nan')] = 2
> >>> d
> {nan: 1, nan: 2}
>
>
> I suspect that's a feature, not a bug.
I don't see how it can be so. Aren't all of those entries garbage?
To compute a histogram of results for computations on a series of
cases would you not have to test each result for NaN-hood, then hash
on a proxy such as the string "Nan"?
_______________________________________________
Python-Dev mailing list
[email protected]
http://mail.python.org/mailman/listinfo/python-dev
Unsubscribe:
http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com