Skip to content

Generalized Implementation of NXN size TicTacToe game to play in console. Wrote it for my nephews

Notifications You must be signed in to change notification settings

SandeepLakka/TicTacToe

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 

Repository files navigation

TicTacToe

Written TicTacToe on my nephew's demand so they can play this on their free time. This implementation allows us to play TicTacToe of any grid of size N×N in addition to standard 3X3

Game can be played in Single player mode against System or in 2 player mode.

Keep in mind that you will be playing against dumbest System ever when in Single player mode. 
System makes dumb decisions and even hangs while finding a appropriate position sometimes! :)

Board size can be changed passing different size to constructor of Board

Input is taken as horizontal,vertical cordinates format

e.g.:

    Enter input : 
    1,2             // <--- 1st row, 2nd column
    Board is 
    ┏━━━┳━━━┳━━━┳━━━┓
    ┃   ┃ O ┃   ┃   ┃
    ┣━━━╋━━━╋━━━╋━━━┫
    ┃   ┃   ┃   ┃   ┃
    ┣━━━╋━━━╋━━━╋━━━┫
    ┃   ┃   ┃   ┃   ┃
    ┣━━━╋━━━╋━━━╋━━━┫
    ┃   ┃   ┃   ┃   ┃
    ┗━━━┻━━━┻━━━┻━━━┛

About

Generalized Implementation of NXN size TicTacToe game to play in console. Wrote it for my nephews

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages