JSFiddle - React, Tailwind, and code Playground
by fristyr
JavaScript
function getRandom (min, max) {
return Math.floor(Math.random() * (max + 1 - min)) + min;
}
console.log(getRandom(0, 1))
console.log("***********************")
console.log(getRandom(0, 1))
console.log("***********************")
console.log(getRandom(-100, 100))
console.log("***********************")