Prog 71: Shorter Double Dice
///Name: Ilana Levy
///Period: 5
///Program Name: Shorter Double Dice
///File Name: shorterDoubleDice.java
///Date Finished: 9/22/2015
import java.util.Random;
public class shorterDoubleDice
{
public static void main( String[] args )
{
Random r = new Random();
int roll1, roll2;
System.out.println( " HERE COME THE DICE!\n" );
do
{
roll1 = 1 + r.nextInt(6);
roll2 = 1 + r.nextInt(6);
System.out.println("Roll #1: " + roll1 + "\nRoll #2: " + roll2 +
"\nThe total is " + (roll1 + roll2) + "!\n" );
}
while ( roll1 != roll2 );
}
}