fix random number max to range