Skip to content

andrewbaldwin44/Mastermind_Ruby_Game

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

25 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Ruby Mastermind Game!

The Mastermind Game and Minimax Algorithm Written for the Odin Project!

Mastermind Game

Demo

Run on Repl.it

How to Play?

Let's Play Mastermind!

The computer is the mastermind! They have created a top secret code that you must crack. You are the code breaker. You must use wits and strategy to break the code! With each guess you make, hints are given as to how close your guess was! Your guess is made by placing four colored pegs on the board. The mastermind will then give you colored clues:

A red clue:
Each red clue means you have placed the correct color, and its in the correct position!

A green clue:
Each green clue means you have placed the correct color, but its not in the correct position! You have 10 turns to guess the code! If you guess the code before your time runs out, you win!

Features

  1. Playing Mastermind against the computer
  2. A minimax algorithm to crack the users code
  3. Difficulty selection

Dependecies

  • Ruby 2.6.5 (or higher)

Run the Project

Clone the repo to your local machine using the terminal:

$ git clone git@github.com:andrewbaldwin44/Mastermind_Ruby_Game.git
  1. Navigate into the project directory cd Mastermind_Ruby_Game
  2. Run the demo ruby main.rb

References

Author

👤 Andrew Baldwin

About

The Mastermind Game and Minimax Algorithm Written for the Odin Project!

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages