Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVA

random number generator

// Javascript
function getRandomInt(max) {
  return Math.floor(Math.random() * max);
}

console.log(getRandomInt(10)); // Integer values: [0, 9]
Source by github.com #
 
PREVIOUS NEXT
Tagged: #random #number #generator
ADD COMMENT
Topic
Name
4+5 =