I get “SyntaxError: unknown: Unexpected token (30:16)” with the following code:
I tried coding along to this video (which passes) but doesn’t pass with my code.
How can I fix this error at line “golfScore(5, 9);”
if (stokes === 1) {
return “Hole-in-one!”;
}
else if (strokes <= (par - 2)) {
return “Eagle”;
}
else if (stokes === (par - 1)) {
return “Birdie”;
}
else if (strokes === par) {
return “Par”;
}
else if (strokes === (par + 1)) {
return “Bogey”;
}
else if (strokes === (par + 2)) {
return “Double Bogey”;
}
else if (strokes >= (par + 3)) {
return “Go Home!”;
}
// Only change code above this line
// Change these values to test
golfScore(5, 9);