tic tac toe 5*5

Submitted on: 7/20/2017 7:14:16 PM
By: kieron chin  
Level: Beginner
User Rating: Unrated
Compatibility: C++ (general)
Views: 24624
     I'm new to c++,do anyone know how to create a tic tac toe with below condition?

				1.	Use a 2D array (or 1D array if you know how to solve) to represent the board. First, name all tile with a number. When a player makes a move, he/she chooses based on the number. If the tile has number instead of ‘O’ or ‘X’, it will fill up with ‘O’ or ‘X’ based on the player’s symbol. Otherwise, it is not a valid move. 
2.	A function to check for valid move as stated in 1.
3.	A function to check for winning condition.
4.	It is suitable to create a function to draw the board on the screen because you are going to display the tile repeatedly throughout the entire game.
5.	Use global variable in a meaningful way. If a variable is used only in 3 or less functions, you should consider pass by value or pass by reference. Inconsistency in code will be penalized (i.e. using global variable at the same time pass the variable to functions)

Report Bad Submission
Use this form to tell us if this entry should be deleted (i.e contains no code, is a virus, etc.).
This submission should be removed because:

Your Vote

What do you think of this article (in the Beginner category)?
(The article with your highest vote will win this month's coding contest!)
Excellent  Good  Average  Below Average  Poor (See voting log ...)

Other User Comments

 There are no comments on this submission.

Add Your Feedback
Your feedback will be posted below and an email sent to the author. Please remember that the author was kind enough to share this with you, so any criticisms must be stated politely, or they will be deleted. (For feedback not related to this particular article, please click here instead.)

To post feedback, first please login.