Problems with Computer Choice Part 1 (Math.random()


#1

This is my code as of now

var userChoice = prompt("Do you choose rock, paper or scissors?")
var computerChoice = Math.random();

And when I run it, I get the message "Oops, try again. Did you remember to log computerChoice to the console?"

I don't know what that means or what I am doing wrong. Help?


#3

You were supposed to log computerChoice to the console. Which means you have to do this:

console.log(computerChoice)


#4

Remember when we learned to use console.log to print things? The exercise is asking you to print the variable called computerChoice.

Do you understand now?


#5

Thank you, now I understand!


#6

If you wanted to go a step further, you could put console.log(userChoice) right below that to show both the users choice and the other player's choice.


#7

console.log(computerChoice);