What does the isNaN() function?

What does the isNaN() function?

1 Like

isNan() function checks if the given value is NaN(Not A Number), If the given value is NaN it returns true.
Example:-
if( isNaN(variable) ) {
//code to be executed if it’s true
} else {
//code to be executed if it’s false
}

2 Likes