game.cpp:2:11: error: expected unqualified-id before numeric constant
#define n 1505
^
game.cpp:5:5: note: in expansion of macro 'n'
int n;
^
game.cpp:6:8: error: 'maxn' was not declared in this scope
int sz[maxn],p[maxn];
^~~~
game.cpp:6:8: note: suggested alternative: 'tan'
int sz[maxn],p[maxn];
^~~~
tan
game.cpp:6:16: error: 'maxn' was not declared in this scope
int sz[maxn],p[maxn];
^~~~
game.cpp:6:16: note: suggested alternative: 'tan'
int sz[maxn],p[maxn];
^~~~
tan
game.cpp: In function 'void initialize(int)':
game.cpp:10:7: error: lvalue required as left operand of assignment
n=N;
^
game.cpp:13:9: error: 'sz' was not declared in this scope
sz[i]=1;
^~
game.cpp:14:9: error: 'p' was not declared in this scope
p[i]=i;
^
game.cpp: In function 'int fnd(int)':
game.cpp:19:11: error: 'p' was not declared in this scope
if(x==p[x])return x;
^
game.cpp:20:5: error: 'p' was not declared in this scope
p[x]=fnd(p[x]);
^
game.cpp: In function 'void unite(int, int)':
game.cpp:31:8: error: 'sz' was not declared in this scope
if(sz[x]<sz[y])swap(x,y);
^~
game.cpp:32:5: error: 'sz' was not declared in this scope
sz[x]+=sz[y];
^~
game.cpp:33:5: error: 'p' was not declared in this scope
p[y]=x;
^
game.cpp: In function 'int hasEdge(int, int)':
game.cpp:43:8: error: 'sz' was not declared in this scope
if(sz[u]+sz[v]<n)
^~