code: public int getNumberBetween(final int min, final int max) {
  
      if (max < min) {
        throw new IllegalArgumentException(String.format("Minimum must be less than minimum (min=%d, max=%d)", min, max));
      }
      if (max == min) {
        return min;
      }
  
      return min + random.nextInt(max - min);
    }
docs: Returns a number betwen min and max
  
  @param min minimum value of result
  @param max maximum value of result
  @return Random number within range