No idea what is wrong with this code but at line 9 and beyond everything I type is more opaque than the rest. I assume this means it is an error. but I even tried copy pasting the normal lines above and they just go opaque. code will not pass.
**Your code so far**
const names = ["Hole-in-one!", "Eagle", "Birdie", "Par", "Bogey", "Double Bogey", "Go Home!"];
function golfScore(par, strokes) {
// Only change code below this line
if (strokes == 1) {
return names[0]
} if else (strokes <= par - 2) {
return names[1]
} if else (strokes == par - 1) {
return names[2]
} if else (strokes == par) {
return names[3]
} if else (strokes == par + 1) {
return names[4]
} if else (strokes == par + 2) {
return names[5]
} if else (strokes >= par - 3) {
return names[6]
}
// Only change code above this line
}
golfScore(5, 4);
**Your browser information:**
User Agent is: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/14.1.2 Safari/605.1.15
Challenge: Golf Code
Link to the challenge: