|
This is the opening activity. The equation here is randomly generated. I did this by creating three variables,
one for the operator and two for the operands. They are all randomly assigned values and put into the textview.
After the result for the current problem is shown, this activity shows again with a new equation.
However the number of problems and the current score are saved and carried over to the other activites,
which show when a method is called.
|
|
Here is the results screen. It shows the final score that has been carried over from all the previous activties.
There has been a variable keeping track of how many correct answers have been given. If it is 4 or more,
a congratulations is in order. Any lower and encouragement to give it another try is given.
|
|
This is what shows when the user gets a correct answer. It shows the current score which is passed through
activties and will go to the equation activity when pressing back. The answer chosen was typed into a textview
in the previous activity, stored into a variable, and compared to the answer. If they are equal, it shows this activity.
|
|
This is what shows when the user gets a incorrect answer. It shows the current score which is passed through
activties and will go to the equation activity when pressing back. The answer chosen was typed into a textview
in the previous activity, stored into a variable, and compared to the answer. If they are inequal, it shows this activity.
|