Practice with arrays and ArrayList
s in Java. More practice with loops and debugging in Java. More practice implementing classes based on a given specification.
Lessons ~ Assignments ~ Survey for assigning partners for the Game of Life exercise
In Eclipse, checkout the ArraysAndLists project.
With your instructor, observe a sample run of your instructor's solution for Main and then review the specification of the project, perhaps by examining its UML class diagram. Note especially that:
Implement and test the methods stubbed in StateList, in the order in which they appear in that class.
Implement and test the methods stubbed in ElectionSimulator, in the order in which they appear in that class.
Implement and test the TODO items in Main, in the order in which they appear in that class.
Here’s an example of the output from my solution for your reference.
main
displays a graphical bar chart of the results in addition to the textual one. Use three different colors for the bars: one for bars representing fewer than half the electoral votes, one for bars representing more than half, and one for a tie.
Note the implementation requirements for the QuizScores exercise:
Big Java, §7.5, may be a helpful reference if you get stuck, as might the summary on arrays and ArrayList's.
You should complete the methods through highestScore by Tuesday, with the rest of the methods due Thursday.
Turn in your programming work by committing it to your SVN repository.