JavaScript course - Modulo if/else is bugged and won't let me go through


So, the instructions are:

Let's get the if/else" statement to display "The first number is even".

1- Edit line 5 by adding a comparison that evaluates to true.
2- In the comparison, use a modulo and an even number, like we did in the example above.

As you can see in the screenshot attached, the line 5 is resulting as TRUE, even displayed by the console. However, for some reason is ignoring the TRUE console log, jumping right in the ELSE, thus not allowing me to go further.

I've checked this and even asked a friend, and the only thing that seems to be happening is a bug. Care to check and see?



I've never seen a function called in a if condition, wich prints to the console (sonsole.log()) :wink:. In if/else condition you have to write statement wich elevate true or false. So try to write 10%2 === 0 instead of console.log().



On this Line

if(console.log(10%2 === 0))

do it like this instead

if (10%2 === 0)

Remove the console.log part in your if condition

Hope this helps


That made it. Thank you, both of you! :smiley: