Skip to content

A simple and fun Tic-Tac-Toe game created using JavaScript, HTML, and CSS.

Notifications You must be signed in to change notification settings

anand-mukul/tic-tac-toe

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Tic-Tac-Toe Game

A simple and fun Tic-Tac-Toe game created using JavaScript, HTML, and CSS. This game supports dynamic grid expansion and timed moves to add more excitement and strategy to the traditional game.

Game Instructions

  1. The game starts with a 3x3 grid.
  2. Player X always goes first.
  3. Players take turns clicking on an empty cell to place their mark (X or O).
  4. Each player has a time limit of 10 seconds to make their move. If a player runs out of time, the other player wins.
  5. The first player to get three of their marks in a row (horizontally, vertically, or diagonally) wins the game.
  6. If all cells are filled and no player has three marks in a row, the game is a draw.
  7. You can expand the grid to 4x4 or 5x5 during the game to add complexity and new strategies.
  8. Click the "RESET" button to restart the game with a 3x3 grid.

Setup

  1. Clone the repository:
    git clone https://github.com/anand-mukul/tic-tac-toe.git
  2. Navigate into the project directory:
    cd tic-tac-toe
  3. Open the index.html file in your favorite web browser to start the game.

About

This Tic-Tac-Toe game was created by Ayush Kumar as a fun project to practice JavaScript, HTML, and CSS. The game features:

  • Dynamic grid expansion (3x3, 4x4, 5x5)
  • Timed moves to add pressure and excitement
  • Simple and clean user interface

Files

  • index.html: The main HTML file that sets up the game layout.
  • style.css: The CSS file that styles the game.
  • script.js: The JavaScript file that contains the game logic.

License

This project is open-source and free to use. Feel free to modify and improve it!


Enjoy the game and have fun strategizing to beat your opponent! If you have any questions or suggestions, feel free to reach out.


Contact


Screenshot

Tic-Tac-Toe Screenshot


Happy playing!