/TIC-TAC-TOE

A Simple TIC TAC TOE Game.

Primary LanguagePython

TIC-TAC-TOE

ABSTRACT:

Tic-Tac-Toe is among the games played between two players played on a 3 x 3 square grid. Each player inhabits a cell in their respective turns, keeping the objective of placing three similar marks in a vertical, horizontal, or diagonal pattern.
The first player utilizes the Cross (X) as the marker, whereas the other utilizes the Naught or Zero (O). According to the turn player should give the place where they need to move.
Initially, we’ll make an empty game board and then we’ll take inputs from the players and we’ll check for the winning condition and if the whole board gets filled and no one wins, we’ll declare the result as “Tie” and ask users if they want to restart the game.
We built this game using dictionaries, for loop, if-else conditions and functions. After building this game, we can get a pretty clear idea about dictionaries in python, how to access dictionaries, how to iterate over dictionaries, for loop, if-else conditions and functions in python.
How does the game work: The board is numbered like the keyboard’s number pad. And thus, a player can make their move in the game board by entering the number from the keyboard number pad.