Answers for "how can i write a function that gives me a random number in nodejs"

5

generate random number nodejs

function getRandomNumberBetween(min,max){
    return Math.floor(Math.random()*(max-min+1)+min);
}
Posted by: Guest on December-31-2019
0

function to generate random number in javascript

function random(number){
    return Math.floor(Math.random()*number);;
}
Posted by: Guest on August-24-2021

Code answers related to "how can i write a function that gives me a random number in nodejs"

Code answers related to "Javascript"

Browse Popular Code Answers by Language