how to generate a random int number in java code example
Example 1: random in java a to b
Min + (int)(Math.random() * ((Max - Min) + 1))
Example 2: java random number generator in range
int rand = ThreadLocalRandom.current().nextInt(x,y);
Min + (int)(Math.random() * ((Max - Min) + 1))
int rand = ThreadLocalRandom.current().nextInt(x,y);