nextDouble() generates a random double from 0.0 to 1.0. I want it to generate a random from .05 to .25 (5% - 25%). However it does not take parameters like nextInt() does. Any suggestions on how to add constraints to it?
nextDouble()
0.0
1.0
.05
.25
nextInt()
Aucun commentaire:
Enregistrer un commentaire