How do you use Math.random to generate random ints?
My code is:
int abc= (Math.random()*100); System.out.println(abc);
All it print
You can also use this way for getting random number between 1 and 100 as:
SecureRandom src=new SecureRandom(); int random=1 + src.nextInt(100);