With or Without Semi Colon?


#1



Build "Rock, Paper, Scissors"


I'm not stuck this is more of a question. This code works with or without semi colons? Which is the best practice - with or without?
;


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

var computerChoice = Math.random();

console.log(computerChoice);


#2

with correctly placed semi-colons, like you did here


#3

I was wondering the same thing. How is one "more" correct than the other, if they both work?


#4

Your Guide to Semicolons in JavaScript by Codecademy
I think it looks better with semicolons.