import java.util.Random;

public class GenRandom {
   // OVERVIEW: GenRandom provides a method for obtaining random numbers.
	
	static private Random rand = new Random ();
	//@invariant rand != null;
	
	//@ensures \result >= 0 && \result < max
	static public int nextInt (int max)
	//  EFFECTS:  returns next randomly selected integer
	{
		return rand.nextInt (max);   
	} //@nowarn Post // ESC/Java doesn't know about Random   
}
// Copied from PS5 - CS201J website