Nothing is equal to NaN
. Any comparison will always be false
.
In both the strict and abstract comparison algorithms, if the types are the same, and either operand is NaN
, the result will be false
.
If Type(x) is Number, then
- If
x
is NaN
, return false
.
- If
y
is NaN
, return false
.
In the abstract algorithm, if the types are different, and a NaN
is one of the operands, then the other operand will ultimately be coerced to a number, and will bring us back to the scenario above.