Category: Front End Web

Illustration explaining NaN in JavaScript, its types, and five common cases resulting in Not-a-Number.

What is NaN in JavaScript? Type of NaN & 3 Edge Cases

NaN stands for “Not-a-Number” and is a special value in JavaScript used to represent a value that is not a valid number. Despite its name, the type of NaN is still “number”. Besides this, NaN is a global property in JavaScript, meaning it is automatically available throughout your code without needing to be explicitly declared.

Read More