Skip to content

A fun and interactive Python-based CLI game where players test their guessing skills by finding a randomly generated number between 1 and 99. With limited attempts, helpful hints, and engaging feedback, this game keeps players entertained while improving their logical thinking.

License

Notifications You must be signed in to change notification settings

Goyam02/Number-Guessing-Game

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 

Repository files navigation

🎲 Random Number Guessing Game

A fun and interactive Python-based CLI game where players test their guessing skills by finding a randomly generated number between 1 and 99. With limited attempts, helpful hints, and engaging feedback, this game keeps players entertained while improving their logical thinking.


📝 Rules of the Game

  1. The game generates a random number between 1 and 99.
  2. You have 7 attempts to guess the correct number.
  3. After each guess, you'll receive feedback:
    • 🔼 "Too High!" if your guess is greater than the number.
    • 🔽 "Too Low!" if your guess is less than the number.
    • "Congratulations!" if you guess correctly.
  4. Enter only valid numbers between 1 and 99. Invalid inputs won't count as attempts.
  5. If you fail to guess correctly in the first 3 attempts, you'll get a hint (e.g., "The number is even").
  6. If you guess the number correctly within 7 attempts, you win! 🎉
  7. If you fail to guess within 7 attempts, the correct number is revealed, and the game ends.
  8. After the game ends, you can choose to play again. 🚀

🚀 How to Play

  1. Clone this repository:
    git clone https://github.com/Goyam02/Random-Number-Guessing-Game.git
  2. Navigate to the project directory:
    cd Random-Number-Guessing-Game
  3. Install required dependencies:
    pip install colorama
    pip install emoji
  4. Run the game:
     ngg.py
    

💡 Features

•	Dynamic Gameplay: Randomly generated number ensures a unique game every time.
•	Hints: Provides hints after 3 failed attempts to assist the player.
•	Interactive Feedback: Real-time messages indicate whether the guess is too high, too low, or correct.
•	User-Friendly Interface: Colored text and emojis for an enhanced CLI experience.
•	Replay Option: Players can replay without restarting the program.

🛠️ Prerequisites

•	Python 3.x
•	Libraries: colorama, emoji

Install the required libraries using:

pip install colorama
pip install emoji

🖥️ Screenshots

Game Screenshot


🤝 Contributions

Contributions are welcome and greatly appreciated! 🎉

To contribute:

  1. Fork the repository.

  2. Create a new branch for your feature or bugfix:

git checkout -b feature-name
  1. Commit your changes:
git commit -m "Add a feature or fix a bug"
  1. Push to your branch:
git push origin feature-name
  1. Open a Pull Request, describing your changes in detail.
Feel free to suggest ideas, report bugs, or enhance the game with new features!

🏆 Acknowledgments

Colorama: For adding vibrant colors to the text.
Emoji: For integrating emojis into the game.


📜 License

This project is licensed under the MIT License. Feel free to use and modify it as you like.

About

A fun and interactive Python-based CLI game where players test their guessing skills by finding a randomly generated number between 1 and 99. With limited attempts, helpful hints, and engaging feedback, this game keeps players entertained while improving their logical thinking.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages