How to use NaN Property in JavaScript
This article describe about NaN Property in JavaScript.
NaN Property in JavaScript
This property work on the Not-a-Number value. and NaN property show that a value is not a legal number.
Note: Value is NaN value then use the isNaN() global function to see it.
Syntax
Example
<!DOCTYPE html>
<html>
<body>
<script type="text/javascript">
var days = 32;
if (days < 1 || days > 31) {
days = Number.NaN;
}
document.write(days);
</script>
</body>
</html>
|
Output

You may also want to read these related articles Click here
Ask Your Question
Got a programming related question? You may want to post your question here
Programming Answers here