error? why?

#include <iostream>
using namespace std;

int main()
bool main()
char main ()

{//1

char board[16] = {};

bool inviboard[16] = {};

int turn = 0;

int n = 1;

char answer;

do
.........
it say missing ';' before identifier 'bool'??
You need a ';' after "bool main()" and "char main()", and I believe "int main()" needs to be directly before the '{'.
1
2
3
int main()
bool main()
char main ()


Why are you attempting to declare three versions of main?

The only accepted one is:

int main()

I'm sorry I dont quite get it can you present it,
#include <iostream>
using namespace std;

1
2
3
4
5
6
7
8
9
10
11
12
13
int main()  // Only one version of main, returning an int 
{
    //1

char board[16] = {};

bool inviboard[16] = {};

int turn = 0;

int n = 1;

char answer;
Last edited on
Topic archived. No new replies allowed.