This program lets you play the classic game of Tic Tac Toe against a computer. The game starts with you first chosing either X or O as your token. The game grid is a 3x3 Double Dimensional Array, where you enter your token in your desired space by inputting the address. E.g. for inputting in the 1st space of the grid your input will be <0,0>. The computer then generates a random move and the game continues. Once, any of the two is able to get 3 in a line, the game ends showing the winner. If the game is not able to reach a conclusion, the game ends in a draw.
sundaramkr / tictactoe-vs.-computer Goto Github PK
View Code? Open in Web Editor NEWA Java program which lets you play Tic-Tac-Toe with a system which generates random moves.