Mastermind

Today you are practicing the modeling and design process. You won’t write any code; the focus is on examining some system – here, a board game – abstracting away the details of the physical board and gameplay, and translating that into a high-level design, in the form of a set of Java classes and methods.

This is a warmup for the upcoming Breakout homework assignment. Unlike many other exercises, that assignment will not provide you with any of the classes specifically related to the game. Just like here, you’ll have to analyze the system and model it first.

How would you represent the Mastermind game using Java? Think about the classes, their state and behaviors, and their relationships.

Bring a diagram of your object model to class. Don’t write any code, except maybe some sketches on paper! This is an exercise in design, not implementation.

Note: You do not need to scan your diagram and post it somewhere! Just bring it to class.