The Random class
One more example to reinforce instantiation and use of objects.
Random class is defined in java.util package.
nextInt() method of Random class returns an integer between 0 and MAXINT of the system.
Example on p.130 : Flipping coins.
Previous slide
Next slide
Back to first slide
View graphic version