// This application simulates throwing a pair of dice import java.util.Random; public class Dice { public static void main(String args[]) { Random random = new Random(); int side1, side2; side1 = Math.abs(random.nextInt())%6+1; side2 = Math.abs(random.nextInt())%6+1; System.out.println("the first die is showing a "+side1); System.out.println("the second die is showing a "+side2); } } /* the first die is showing a 4 the second die is showing a 3 */