Math.random()
(int) (Math.random())
0
(int) Math.random() *5
0
(int) (Math.random() * 2)
0 or 1
(Math.random())
0.0 <= x < 1
(Math.random()*10)
0.0 <= x < 10.0
(int) Math.random()*5 + 1
1
(int) (Math.random() * 2 + 5)
5 or 6
(int) (Math.random() * 11)
Integer 0-10, inclusive
(int) (Math.random() * 13)
Integer 0-12, inclusive
(int) (Math.random() * 20)
Integer 0-19, inclusive
(int) (Math.random() * 3)
Integer 0-2, inclusive
(int) (Math.random() * 4)
Integer 0-3, inclusive
(int) (Math.random() * 5)
Integer 0-4, inclusive
(int) (Math.random() * 9)
Integer 0-8, inclusive
(int) (Math.random() * 10)
Integer 0-9, inclusive
(int) (Math.random()*100)
Integer 0-99, inclusive
(int) (Math.random() * 10 + 1)
Integer 1-10, inclusive
(int) (Math.random() * 11 + 1)
Integer 1-11, inclusive
(int) (Math.random() * 5 + 1)
Integer 1-5, inclusive
(int) (Math.random() * 9 + 1)
Integer 1-9, inclusive
(int) (Math.random() * 13 + 10)
Integer 10-22, inclusive
(int) (Math.random() * 3 + 2)
Integer 2-4, inclusive
(int) (Math.random() * 4 + 2)
Integer 2-5, inclusive
(int) (Math.random() * 20 + 5)
Integer 5-24, inclusive