Skip to content

Instantly share code, notes, and snippets.

View nichia's full-sized avatar

Ni Chia nichia

View GitHub Profile

Keybase proof

I hereby claim:

  • I am nichia on github.
  • I am nichia (https://keybase.io/nichia) on keybase.
  • I have a public key ASBACMeneMxjKaf3TNBqZCmcBPN2duVU9rf9GG82K5WoKgo

To claim this, I am signing this object:

var userChoice = prompt("Do you choose rock, paper or scissors?");
console.log("User: " + userChoice);
var computerChoice = Math.random();
if (computerChoice < 0.34) {
computerChoice = "rock";
} else if(computerChoice <= 0.67) {
computerChoice = "paper";
} else {