Help with Excercise 19 Math


Help, All I keep getting is Syntax error, cannot work out what is correct format.any assistance gratefuly recieved.

SyntaxError: Unexpected token )

Replace this line with your code. 
 if ("Jon".length * 2 / (2+1) === )
    console.log("The answer makes sense!");
    console.log("Error Error Error")


Instruction says:

Complete the missing bits of code to construct the if / else statement. Make the condition evaluate to true.

So you need complete condition for if statement. Left side has 3 * 2 / 3 = 2. To make the condition evaluate to true right side should be equal to left.


Thanks for that explanation - did as you suggested and it worked, but not really sure why or how.
Will continue and it may become clearer at a later date.
Thanks Graham


More details you can find here: The if Statement.


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