8. What if choice1 is scissors?


#1


https://www.codecademy.com/en/courses/javascript-beginner-en-Bthev-mskY8/1/4?curriculum_id=506324b3a7dffd00020bf661#


SyntaxError: Unexpected end of input


https://gist.github.com/daab3bbb1399efd5699e2047bcd041bb


#2

SyntaxError: Unexpected end of input

you didnt close your function at the end after closing third else if


#3

else if (choice1 === "scissors") {
    if (choice2 === "rock") {
        return "rock wins";
}
    else {
        return "paper wins";}
    }
}
compare(userChoice, computerChoice);
console.log(compare);

#4

console.log(compare);

you dont need it

also who will win if inputs are scissors and paper ?


#5

Good point haha! Got it all fixed up. Thanks for your help!


#6

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