Random r=new Random();

r.nextInt(n) genera un intero tra 0 e n-1
r.nextBoolean() genera un boolean
e così via...