0_0_17197377_29681.cpp:139:11: error: redefinition of 'const int maxn'
const int maxn = 30;
^
0_0_17197377_29681.cpp:6:11: note: 'const int maxn' previously defined here
const int maxn = 1010;
^
0_0_17197377_29681.cpp:140:11: error: redefinition of 'const int maxm'
const int maxm = 100100;
^
0_0_17197377_29681.cpp:7:11: note: 'const int maxm' previously defined here
const int maxm = maxn*maxn;
^
0_0_17197377_29681.cpp:146:11: error: conflicting declaration 'edge mapp [1020100]'
}mapp[maxm];
^
0_0_17197377_29681.cpp:13:2: note: previous declaration as 'node mapp [1020100]'
}mapp[maxm];
^
0_0_17197377_29681.cpp:147:5: error: redefinition of 'int id'
int id, n;
^
0_0_17197377_29681.cpp:15:5: note: 'int id' previously declared here
int id;
^
0_0_17197377_29681.cpp:147:9: error: redefinition of 'int n'
int id, n;
^
0_0_17197377_29681.cpp:16:5: note: 'int n' previously declared here
int n, m;
^
0_0_17197377_29681.cpp:148:18: error: redefinition of 'bool visited [1020100]'
bool visited[maxm];
^
0_0_17197377_29681.cpp:17:6: note: 'bool visited [1020100]' previously declared here
bool visited[maxm];
^
0_0_17197377_29681.cpp:149:14: error: redefinition of 'int head [1010]'
int head[maxn];
^
0_0_17197377_29681.cpp:14:5: note: 'int head [1010]' previously declared here
int head[maxn];
^
0_0_17197377_29681.cpp:150:5: error: conflicting declaration 'int ans'
int ans;
^
0_0_17197377_29681.cpp:18:6: note: previous declaration as 'node ans [1020100]'
node ans[maxm];
^
0_0_17197377_29681.cpp: In function 'void init()':
0_0_17197377_29681.cpp:152:6: error: redefinition of 'void init()'
void init()
^
0_0_17197377_29681.cpp:21:6: note: 'void init()' previously defined here
void init()
^
0_0_17197377_29681.cpp: In function 'void addedge(int, int)':
0_0_17197377_29681.cpp:158:6: error: redefinition of 'void addedge(int, int)'
void addedge(int u, int v)
^
0_0_17197377_29681.cpp:29:6: note: 'void addedge(int, int)' previously defined here
void addedge(int u, int v)
^
0_0_17197377_29681.cpp: In function 'int main()':
0_0_17197377_29681.cpp:184:5: error: redefinition of 'int main()'
int main()
^
0_0_17197377_29681.cpp:62:5: note: 'int main()' previously defined here
int main()
^
0_0_17197377_29681.cpp:192:15: error: incompatible types in assignment of 'int' to 'node [1020100]'
ans = 0;
^
0_0_17197377_29681.cpp: At global scope:
0_0_17197377_29681.cpp:242:5: error: redefinition of 'int n'
int n, m;
^
0_0_17197377_29681.cpp:16:5: note: 'int n' previously declared here
int n, m;
^
0_0_17197377_29681.cpp:242:8: error: redefinition of 'int m'
int n, m;
^
0_0_17197377_29681.cpp:16:8: note: 'int m' previously declared here
int n, m;
^
0_0_17197377_29681.cpp:244:20: error: conflicting declaration 'int mapp [410][410]'
int mapp[size][size];
^
0_0_17197377_29681.cpp:13:2: note: previous declaration as 'node mapp [1020100]'
}mapp[maxm];
^
0_0_17197377_29681.cpp:245:18: error: conflicting declaration 'bool visited [410]'
bool visited[size];
^
0_0_17197377_29681.cpp:17:6: note: previous declaration as 'bool visited [1020100]'
bool visited[maxm];
^
0_0_17197377_29681.cpp: In function 'void hanmi(int*, int&)':
0_0_17197377_29681.cpp:258:21: error: no match for 'operator[]' (operand types are 'node' and 'int')
if (mapp[s][i]){
^
0_0_17197377_29681.cpp:269:29: error: no match for 'operator[]' (operand types are 'node' and 'int')
if (mapp[t][j] && !visited[j]){
^
0_0_17197377_29681.cpp:283:29: error: no match for 'operator[]' (operand types are 'node' and 'int')
if (mapp[t][j] && !visited[j]){
^
0_0_17197377_29681.cpp:292:22: error: no match for 'operator[]' (operand types are 'node' and 'int')
if (!mapp[s][t]){//若当前st不构成回路
^
0_0_17197377_29681.cpp:294:35: error: no match for 'operator[]' (operand types are 'node' and 'int')
if (mapp[ans[i+1]][s] && mapp[ans[i]][t]){
^
0_0_17197377_29681.cpp:294:54: error: no match for 'operator[]' (operand types are 'node' and 'int')
if (mapp[ans[i+1]][s] && mapp[ans[i]][t]){
^
0_0_17197377_29681.cpp:306:34: error: no match for 'operator[]' (operand types are 'node' and 'int')
if (mapp[ans[i]][j])break;
^
0_0_17197377_29681.cpp:308:30: error: no match for 'operator[]' (operand types are 'node' and 'int')
if (mapp[ans[i]][j])break;
^
0_0_17197377_29681.cpp: In function 'int main()':
0_0_17197377_29681.cpp:318:5: error: redefinition of 'int main()'
int main()
^
0_0_17197377_29681.cpp:62:5: note: 'int main()' previously defined here
int main()
^
0_0_17197377_29681.cpp:325:24: error: no match for 'operator[]' (operand types are 'node' and 'int')
mapp[a][b] = mapp[b][a] = 1;
^
0_0_17197377_29681.cpp:325:37: error: no match for 'operator[]' (operand types are 'node' and 'int')
mapp[a][b] = mapp[b][a] = 1;
^
0_0_17197377_29681.cpp:329:26: error: no match for 'operator[]' (operand types are 'node' and 'int')
mapp[i][j] ^= 1;
^
0_0_17197377_29681.cpp:330:26: error: no match for 'operator[]' (operand types are 'node' and 'int')
mapp[j][i] ^= 1;
^
|