Tic Tac Toe Game

This is a simple command-line implementation of the classic Tic Tac Toe game in Python.

How to Run

  1. Ensure you have Python installed on your machine. You can download it from Python.

  2. Clone the repository to your local machine:

git clone https://github.com/GOR-OM/Tick-Tack-Toe.git

  1. Navigate to the project directory:

  2. Run the game:

python tic_tac_toe.py

How to Play

  1. The game starts with an empty 3x3 board.
  2. Players take turns entering a value (0-8) to place their symbol ('X' or 'O' on the board.
  3. The game continues until one player wins or the board is full, resulting in a draw.

Game Controls

  • Player 'X' is prompted to enter a value during their turn.
  • Player 'O' is prompted to enter a value during their turn.

Example

Welcome to Tic Tack Toe
0 | 1 | 2
--|---|--
3 | 4 | 5
--|---|--
6 | 7 | 8
X chance
Please enter a value (0-8): 0
X | 1 | 2
--|---|--
3 | 4 | 5
--|---|--
6 | 7 | 8
O chance
Please enter a value (0-8): 1
X | O | 2
--|---|--
3 | 4 | 5
--|---|--
6 | 7 | 8
X chance
Please enter a value (0-8): 2
X | O | X
--|---|--
3 | 4 | 5
--|---|--
6 | 7 | 8
O chance
Please enter a value (0-8): 3
X | O | X
--|---|--
O | 4 | 5
--|---|--
6 | 7 | 8
X chance
Please enter a value (0-8): 4
X | O | X
--|---|--
O | X | 5
--|---|--
6 | 7 | 8
O chance
Please enter a value (0-8): 5
X | O | X
--|---|--
O | X | O
--|---|--
6 | 7 | 8
X chance
Please enter a value (0-8): 6
X won the match
---------------------------------------------
X | O | X
--|---|--
O | X | O
--|---|--
X | 7 | 8