2 ms·
Stuffed-Na(a)N: stuff your NaNs
- skerit 2y agoWhat? `NaN` isn't some primitive constant like `true`, `false`, `null` or `undefined`? It _actually_ is a number?
- dgroshev 2y agoYes! Since any function returning a float might need to return NaN, NaNs are represented as a special kind of float, with most bits unused.
- skerit 2y agoCool. Is that why NaN isn't equal to anything? Not even when comparing a NaN variable to itself? (I assume it's because you can't have some NaN values be equal, and others not)