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

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

Basic Tic Tac toe game
https://github.com/kanishk1420/tic-tac-toe

javascript tic-tac-toe

Last synced: 3 months ago
JSON representation

Basic Tic Tac toe game

Awesome Lists containing this project

README

        

# Tic-Tac-Toe
Basic Tic Tac toe game
Currently i only made skeleton of it i will add the more designing and more good features while learning react
things are slow but in good way!
# The Board:
Tic-Tac-Toe is played on a 3x3 grid (though some brave souls venture into 4x4 territory).
Each square represents a potential move.
Players and Symbols:
You’re either X or O.
Players take turns placing their symbols in empty squares.
Objective:
The goal? Get three of your marks in a row—horizontally, vertically, or diagonally.
When you achieve this, you’re the winner!
Gameplay:
Player 1 (let’s say it’s you) places an X or an O in an empty square.
Player 2 (your opponent) takes their turn.
Keep alternating until someone wins or all squares are filled.
Winning:
If you manage to create a row of three of your symbols, you win!
It can be a straight line (up, down, or across) or a diagonal.
Blocking and Strategizing:
If your opponent is about to win, block them!
Simultaneously, focus on creating your own winning row.
The Center Square:
If you go first, claim the center square—it’s the best move.
Why? It maximizes your chances of winning.
Optimal Play:
With perfect play from both sides, Tic-Tac-Toe ends in a draw.
But hey, that won’t stop us from trying to outwit each other!