Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVA

how generate a random number in java between 3 and 5

public int getRandomNumber(int min, int max) {
    return (int) ((Math.random() * (max - min)) + min);
}
 
PREVIOUS NEXT
Tagged: #generate #random #number #java
ADD COMMENT
Topic
Name
3+8 =