How to define isNan


Oops, try again. It looks like you have an error in your code! See the error message for more details: ReferenceError: isNan is not defined

var isEven = function(number) {
  if(number%2 === 0){
      return "true";
  else if(isNan() ){
      return "I understand";
      return "false";



isNan should be structured like this (isNaN(number)) - Capitalisation is important.

You are also supposed to return Boolean values true and false rather than the strings true and false. But you are right when you return a string for the isNaN else if.


thanks alot for the help!


This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.