Rock, paper and scissors game


#1

Can someone tell me if their code indicates who wins because my code didn't, despite calling the function: compare("userChoice", computerChoice)


#2

You need to use userChoice not "userChoice". userChoice would be a variable that you assigned "rock", "paper" or "scissors" to by using the prompt and "userChoice" is just a the word "userChoice". As there is no case dealing with this word you probably don't see a result or undefined if you'd wrap your function call in a console.log.