You are on page 1of 1

Into to C++

Tic-Tac-Toe Project Design

Project Design
Variables needed are: Player 1 name Player 2 name Various variables that serve as counters, such as to decide whose turn it is String variables for tile placement How to Share: The 2 players will simply take turns. Whoever wishes to go first will be player 1. User interface: Initially, the game will ask for player 1 and 2's names. Then, the board will be displayed, and player 1 will go first. The game will say "Choose your move" , and allow the player to input the move. An updated board will appear, displaying the player's move, and will ask player 2 to play their move. The game will repeat until a player wins or there is a tie. Then, players can restart the game or terminate it. Program Flow: Algorithm Functions to be isolated: A function to take read input to see if it has been already used, a function to detect 4 in a row, a function to clear the data on reset. Others: None.

Contributors: Han Lu Ling