https://github.com/mgrdich/mastermind
https://github.com/mgrdich/mastermind
Last synced: about 1 year ago
JSON representation
- Host: GitHub
- URL: https://github.com/mgrdich/mastermind
- Owner: Mgrdich
- Created: 2023-05-13T08:16:21.000Z (about 3 years ago)
- Default Branch: master
- Last Pushed: 2023-05-21T20:19:33.000Z (about 3 years ago)
- Last Synced: 2025-02-14T11:52:12.081Z (over 1 year ago)
- Language: Jupyter Notebook
- Size: 69.3 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: Readme.md
Awesome Lists containing this project
README
# MasterMind
This the is MasterMind Project , optimized to run the binary case.
## How to Start the Game
* Download `pipenv` by running `pip install --user pipenv`
* `cd` go to the project directory
* Create Virtual env `pipenv`
* Run the file `python ./main.py`
## How to play the game
You have two options to play the game
* is that you are the player
* Or you can sit and watch the computer do its thing
For now if you want the autoplay mode when the computer does all the guesses for you
`masterMind = MasterMindBinary(auto_play=True)`
if you want to cheat and see the computer generated number choose
`masterMind = MasterMindBinary(show_computer_guess=True)`
Default game parameter of the game is guessing binary number of `4` bits , with `10` guesses To change the option
`masterMind = MasterMindBinary(bits=int, number_of_guesses=int)`
In the future you will be able to toggle those parameters with the shell flags
`masterMind.play_game()` is the one that kicks off the algorithm
`masterMind.print_results()` is where you see your result
but steps by step algorithm has logs , it will be configurable in the future.
In the data_representation file is the basic plots of the algorithms