using Random class for generating random ints