C++ hackers anyone?
#include <iostream.h>
using namespace std;
void initVars()
{
char board[9] = {'1', '2', '3', '4', '5', '6', '7', '8', '9'};
}
void displayBoard()
{
cout << " | | " << endl;
cout << " " << board[0] << " | " << board[1] << " | " << board[2] << " " << endl;
cout << "---|---|---" << endl;
cout << " " << board[3] << " | " << board[4] << " | " << board[5] << " " << endl;
cout << "---|---|---" << endl;
cout << " " << board[6] << " | " << board[7] << " | " << board[8] << " " << endl;
cout << " | | " << endl;
}
int main()
{
initVars();
displayBoard();
cin.ignore();
}
12 C:\Dev-Cpp\Untitled1.cpp `board' undeclared (first use this function)
|