In this homework, you will implement a simple MasterMind game, played with digits.
When the (single) activity is started, the activity generates a 4-digit number, which the user must guess. The user enters guesses in the top of the screen, using the normal keyboard. The application gives feedback; for instance, if the secret number is 1213 and the user enters 1234, the feedback would be:
1234 C:2 M:1
Which means:
As the user enters more and more guesses, the feedbacks are added to a list of feedbacks.
The screen would look something like this:
Where the Item 1, Item 2, ... are the list of feedbacks. For instance, after two guesses, the list may contain:
4235 C:1 M:1
1234 C:2 M:1
With the most recent guess being on top.
There should be a menu option (use the options menu), with an icon, that enables the user to start a new game.
Submit a solution to this somewhat unsophisticated assignment, by submitting the .zip and .apk files.
If you really want to do extra, you can think at how to allow better number entry (a keypad? some other way?), and colorful feedback more in the style of the true MasterMind game, but this is entirely optional, and you should submit it separately if you wish.
The code for the Chapter 2 ToDo List in the textbook can be a good starting point.