Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- let firstRandom = Math.round((Math.random()*8+1));
- let lastRandom = Math.round((Math.random()*8+1));
- let question = parseInt(prompt('what is '+ firstRandom + '*' +
- lastRandom));
- if(question === firstRandom * lastRandom) {
- alert("You are correct!");
- } else {
- alert("You are wrong");
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement