import java.util.Random; // add the ArrayList and Collections libraries: _____________________________________________ _____________________________________________ public class GameUndone { public static void main (String[] args) { Random r = new Random(); // create two players Player one = new Player("Sally"); Player two = new Player("John"); // Instead of the above 2 lines, // create an arraylist _____________________________________________ _____________________________________________ _____________________________________________ _____________________________________________ // play 5 rounds of a game that // has one die per turn for (int c = 0; c < 5; c++){ int roll = r.nextInt(6) +1; one.move(roll); System.out.println(one); roll = r.nextInt(6) +1; two.move(roll); System.out.println(two); // instead of repeating these 3 lines // make a loop using a for each loop _____________________________________________ _____________________________________________ _____________________________________________ _____________________________________________ } // after the game, print both once more // - print the players in sorted order _____________________________________________ _____________________________________________ _____________________________________________ _____________________________________________ } }