Create a java program that, via a java GUI and event driven programming, plays a simple game:
Question:
Create a java program that, via a java GUI and event driven programming, plays a simple game: trying to predict if the next random number between 1 and 100 will be higher or lower than the current random number.
The GUI will display a Text control showing the current random number, a Text control showing the user's score, and two buttons: higher and lower.
When the program starts, a random number between 0 and 99 is generated and displayed in the GUI. The user clicks on the higher or lower button.
A new random number is generated and displayed. If the user's guess was correct, they get 10 more points. If their guess was incorrect, they get zero points. After each guess the score is updated and displayed in the GUI.
Additional requirements:
- Use one of the Java containers (H Box, V Box, Grid, Border. whatever...) to organize your GUI components.
- Set the Stage's title to be "Guessing Game by" and your first and last name