Skip to content

A simple Java console game where the player tries to guess a randomly generated number within a range, with hints provided after each guess.

Notifications You must be signed in to change notification settings

gaurav110601/guess-the-number

Folders and files

NameName
Last commit message
Last commit date

Latest commit

ย 

History

3 Commits
ย 
ย 
ย 
ย 

Repository files navigation

Guess the Number ๐ŸŽฏ

A fun and interactive Java console game where the computer randomly selects a number, and the player has to guess it!

๐ŸŽฎ How It Works

  • The program generates a random number within a given range.
  • The player is prompted to guess the number.
  • Hints like "Too high" or "Too low" are provided after each guess.
  • The game continues until the correct number is guessed.
  • Tracks the number of attempts taken.

๐Ÿ›  Technologies Used

  • Java (JDK 8+)
  • Console-based I/O

๐Ÿ’ก Example

Welcome to Guess the Number!
I have selected a number between 1 and 100.
Try to guess it!

Enter your guess: 50
Too low!

Enter your guess: 75
Too high!

Enter your guess: 65
Congratulations! You guessed the number in 3 attempts.

๐Ÿ“ซ Contact

Created by Gaurav Sharma
LinkedIn


Use it, share it, and improve it โ€“ happy calculating!

About

A simple Java console game where the player tries to guess a randomly generated number within a range, with hints provided after each guess.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages