Lesson 8 What if choice 1 is scissors


#1

Below is my code .The editor says "syntax error""

    else if(choice1==="scissors"){
if(choice2==="paper"){
    return "scissors wins";
}
}
else {
    return"rock wins";
}
}
}

compare(userChoice, computerChoice);


#2

else if(choice1==="scissors"){
if(choice2==="paper"){
    return "scissors wins";
} /* closes if */
} /* closes else if */

I added some comments in a snippet of your code. The second closing curly bracket closes the else if, but the else on the line should be inside else if


#3

i think ur missing the semi-colon on your last curly bracket


#4

You have waaaaay to many ending curly brackets. way to many. You need ot make sure that every beginning curly bracket has a end one. The correct way to write this:

Also make sure to format it correctly too, so you know that the "if" statement is inside the "else if" statement.