An open API service indexing awesome lists of open source software.

https://github.com/tolmen/guestsecretcode

A console game in Java where the player has to guess a randomly generated secret combination in the fewest attempts possible.
https://github.com/tolmen/guestsecretcode

game guessing-game java

Last synced: 10 months ago
JSON representation

A console game in Java where the player has to guess a randomly generated secret combination in the fewest attempts possible.

Awesome Lists containing this project

README

          

# GuestSecretCode ๐ŸŽฎ๐Ÿ”

> **Project created as part of my training for the BTS SIO.**
> --> *Version : [Franรงais](README_fr.md)* ๐Ÿ“–

## ๐Ÿ“– Overview

**GuestSecretCode** is a console game in **Java** where the player must guess a randomly generated secret combination.
The objective is to propose combinations and analyze the hints provided on the number of correctly placed digits.
The challenge? Find the correct combination in a **minimum number of attempts**!

## ๐ŸŽฒ How to play ?

1. **Start the game** : After running the program, choose the length of the combination to guess.
2. **Make a guess** : Enter a combination of digits.
3. **Hints** : The game tells you how many digits are correctly placed.
4. **Win** : Keep going until you find the secret combination!

## ๐Ÿš€ Installation

### Prerequisites
- **Java JDK 8+** : Make sure you have Java installed on your machine.
- **IDE or Terminal** : You can run the game in an IDE (NetBeans, IntelliJ, Eclipse) or directly via a terminal.

### Installation Steps

1. **Clone the repository**
```sh
git clone https://github.com/TolMen/GuestSecretCode.git
```
OR
```sh
git clone git@github.com:TolMen/GuestSecretCode.git
```

2. **Compile the project**
In a terminal, navigate to the project folder and compile the code :
```sh
javac GuestSecretCode/GuestSecretCode.java
```

3. **Run the game**
Once the compilation is done, start the game with :
```sh
java GuestSecretCode.GuestSecretCode
```

## ๐Ÿ’ก Possible improvements

This project serves as a base for a console game, but it can be enhanced with :

- โœ… Displaying the number of misplaced digits.
- โœ… Limiting the number of attempts before failure.
- โœ… Adding a graphical user interface for a better user experience.

---

Thank you for taking the time to explore this project.

Feel free to explore, learn, and modify it ! โœจ

For any questions or collaboration, feel free to reach out ! ๐Ÿ“ฉ

[TolMen](https://github.com/TolMen) - [LinkedIn](https://www.linkedin.com/in/jessyfrachisse/)

๐Ÿ”’ Good luck finding the secret combination !