Guess the Number is a simple game where the player needs to guess a randomly generated number. The program uses Java and the JOptionPane
library to display dialog boxes.
In this game, the player is prompted to guess a number within a specified range (e.g., from 1 to 100). The program provides feedback on whether the guessed number is higher or lower than the target number. At the end of the game, the actual number is revealed to the player.
- Random number generation.
- User input via
JOptionPane
. - Display of the target number at the end of the game.
- Option to start a new game after the current one ends.