Reputation: 53
My code is :
// Define quarter here.
var quarter = function(number);
{
return number / 4;
}
if (quarter(12) % 3 === 0 ) {
console.log("The statement is true");
} else {
console.log("The statement is false");
}
It returns "SyntaxError: Unexpected token"
Can someone point me to my error. Thanks
Upvotes: 0
Views: 35
Reputation: 4515
var quarter = function(number);
needs to be
var quarter = function(number)
The semicolon is the unexpected token.
Upvotes: 1