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

https://github.com/krikoset2/tic-tac-toe

A tic-tac-toe game in c++
https://github.com/krikoset2/tic-tac-toe

cpp game terminal-game

Last synced: over 1 year ago
JSON representation

A tic-tac-toe game in c++

Awesome Lists containing this project

README

          

# Tic Tac Toe Game

A classic Tic Tac Toe game where you play as "X" against the computer (who plays as "O"). The computer uses a minimax algorithm for optimal play.

## How to Play

1. You will be "X" and the computer will be "O".
2. Enter a number between 1 and 9 to make your move (corresponding to the grid positions).
3. The first player to get three in a row (horizontally, vertically, or diagonally) wins.
4. If the board is full and there is no winner, the game ends in a tie.

## Commands

- **Enter a number (1-9)**: To make your move on the Tic Tac Toe grid.
- **Play Again**: After the game ends, type `Y` or `y` to start a new game.

Enjoy the game!

## License

MIT License.