ICS 111 Homework Assignment H09: Graphical Pair of Dice

1) Create a class GraphicalPairOfDice that extends PairOfDice. GraphicalPairOfDice should have a method

 * Draws the given die at x and y.
 * @param g The Graphics context.
 * @param dieNum the number of the die either 1 or 2.
 * @param x the x location for the die.
 * @param y the y location for the die.
public void drawDie(Graphics g, int dieNum, int x, int y) {
  // your code here.

2) Modify the Exercise 3 for Chapter 6 to use your GraphicalPairOfDice.

Turning in the Assignment

The assignment is due on Friday at 11:55pm. You may turn it in early.

  1. Conduct a personal review of your code before turning it in. Does your code follow the Java Coding Standard?

    Is it clear and well commented?

  2. Test your code.

    • Does it produce the correct output?
  3. Sign into Laulima, then navigate to the ICS111 site. In the left hand side of the site, there is an Assignments tab/link. Click on it and view all of the posted assignments. Select the assignment that you want to turn in and attach your files and accept the honor pledge to submit the assignment.