More on Control flow debugging


var didgit = Math.floor(Math.random()*Math.random()+ 2)
var isEven = function(number) {
  // Your code goes here!
      return false;
      return true;

Still don't understand why this doesn't work.


would you mind sending a link? and maybe the error message please?


Your syntax looks fine so I think it might have something to do with the instructions



you did a lot of extra work here. all you needed to do was make it any number you want
my version of this was var number = 36.
that seems to be the only difference between mine and your code


your code might work if you change the variable name to number instead of didgit


or change the parameter to didgit instead of number


It's now giving me this:

Oops, try again. Looks like your function returns false when number = 3. Check whether your code inside the if/else statement correctly returns true if the number it receives is odd.


ok can you send me the current code?


var didgit = 36
var isEven = function(number) {
return true;
return false;


change number to didgit


Thank you so much! Big help right there.


no problem man, good luck on the rest of the course


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