cplusplus.com
C++ : Forum : Beginners : Im a bit confused(Tic-Tac-Toe)
 
cplusplus.com
Information
Documentation
Reference
Articles
Forum
Forum
Beginners
Windows Programming
UNIX/Linux Programming
General C++ Programming
Lounge
Jobs


question Im a bit confused(Tic-Tac-Toe)

Chrislee123 (41)
Thats my code src so far and well im getting a bit confused. I have globally defined the XOboard and well i think ive made the clear board function but im confused about the rest how I do it and what i use.

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
#include <iostream>
#include <conio.h>

using namespace std;

void Input(); 
void ClearBoard(); 
void Process(); 
char XOBoard[2][2] = {};

int main(){
}


void Input(){
     cout << "Please enter the x coordinate...";
     cin >> x;
     cout << "Please enter the y coordinate...";
     cin >> y;
     }

void Process(){
     }

void ClearBoard(){
    for(int x = 0; x<2; x++){
            for(int y = 0; y<2; y++){
                    cout << XOBoard[x][y] << " ";
                    }
            cout << endl;
}
}
Last edited on
helios (9408)
Okay, so what do you want from us?
Chrislee123 (41)
To tell me what I need like what functions what goes in the functions, etc.
anilpanicker (102)
The board should be 3X3, not 2X2
Chrislee123 (41)
Oh i thought using arrays it made the 0,1,2. Hmmm my bad ill make 3,3.

Anything else?
anilpanicker (102)
See this post
http://www.cplusplus.com/forum/beginner/3041/
Chrislee123 (41)
kk thank you!!
Chrislee123 (41)
wow thats way to confusing.....
Topic archived. No new replies allowed.