// Java code to demonstrate the working
// of nextInt()
import java.util.*;
public class NextInt1 {
public static void main(String[] args)
{
// create random object
Random ran = new Random();
// generating integer
int nxt = ran.nextInt();
// Printing the random Number
System.out.println
("The Randomly generated integer is : " + nxt);
}
}