A simple Tic-Tac-Toe game built using HTML, CSS, and JavaScript.
You can play the game live here.
- Interactive game board
- Two players (X and O)
- Win detection and game over state
- Reset option to start a new game
- HTML
- CSS
- JavaScript
These instructions will help you get a copy of the project up and running on your local machine for development and testing purposes.
You will need a web browser to run the game. Make sure you have one installed.
-
Clone the repository:
-
Navigate to the project directory:
-
Open
index.html
in your web browser.
-
Open the game in your web browser.
-
The game board will be displayed, with a 3x3 grid.
-
Player X starts the game. Click on an empty cell in the grid to place your marker (X or O).
-
Alternate turns with the other player, clicking on empty cells to place markers.
-
The first player to get three of their markers in a horizontal, vertical, or diagonal row wins the game.
-
If all cells are filled and no player has won, the game ends in a draw.
-
To start a new game, click on the "Reset" button.