Question
//*** What is the main purpose of this do-while loop? //*** //*** Your comments here //*** do { System.out.println(); System.out.print(PRESS_ENTER_MESSAGE); // Pause for the enter
//*** What is the main purpose of this do-while loop? //*** //*** Your comments here //*** do { System.out.println(); System.out.print(PRESS_ENTER_MESSAGE);
// Pause for the enter key. input.nextLine();
// Keep track of the number of turns the player uses. turnCount++;
// Roll the dice the first time. die1 = generator.nextInt(MAX_NUMBER_ON_DIE) + 1; die2 = generator.nextInt(MAX_NUMBER_ON_DIE) + 1; die3 = generator.nextInt(MAX_NUMBER_ON_DIE) + 1; die4 = generator.nextInt(MAX_NUMBER_ON_DIE) + 1; die5 = generator.nextInt(MAX_NUMBER_ON_DIE) + 1;
// Keep track of the number of rolls per turn. numberOfRolls = 1;
// Display the values of the dice after rolling. displayDice();
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started