Closed jordanallain closed 5 years ago
IEEE 754 standard, a standard for floating point arithmetic, defines arithmetic formats comprising of finite numbers, infinities and NaN(a special value). In simple words, NaN is a result of operations that yield values that cannot be represented or defined as floating point numbers. It is still a number, but we don't have a proper representation for it. Take an example of square root of a negative number, it is imaginary, therefore we represent it using NaN.
yes like i said i understand it makes sense but thought it still was appropriate for this repo.
Feel free to open a PR where we can discuss this further.
I thought you could expand on the NaN being a number type a little.
Type of NaN is a 'number':
this is almost seemingly contradicting itself because it tells you that NaN is type number, but that NaN is indeed not a number. i understand it makes sense but at first glance i think it makes you think "wtf?"
also,
NaN === NaN
orNaN == NaN
is false both times but may not be as applicable to this section