Step 9 Next steps: Am I doing the right thing? Should we follow the previous format like this? Assist kindly


#1

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


`

Replace this line with your code.

var varName = "userChoice"
var computerChoice = Math.random()
if (computerChoice <= 0.25){
computerChoice ="rope";
}
else {
computerChoice ="dog";

var compare = function(choice1, choice2) {
if(choice1 === choice2) {return "The result is a tie";}
else if(choice1 === "rope"){
if(choice2 === "dog"){
return "dog wins";
}
}


#2

Or kindly send me an example the expected code/syntax for the game.


#3

the instruction is a recommendation of what you could do after. so replace the dog and rope with rock, paper, and scissors, and it should work


#4

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