Answers for "javascript mathrandom"

7

random js

function randomNumber(min, max) {
  return Math.floor(Math.random() * (max - min)) + min + 1;
}
Posted by: Guest on June-27-2020
0

js math random

var n = Math.random();
n = Math.floor((n * 6) + 1); // if you want your numbers to start at 1 and end at 6 
console.log(n);
Posted by: Guest on May-11-2021
0

random math js

(Math.random()*100).toFixed(0)
Posted by: Guest on July-20-2021

Code answers related to "Javascript"

Browse Popular Code Answers by Language