News

How to Make Random Images Appear in Java. The Java "Random" class lets you generate a random number for your Java apps. You use this number generator to randomize images shown in your apps.
Add the "Random" class library to the top of the source code file. Add the following code to the top of your file:import java.util.Random; Create a random number.