/in/foo.cc:4:14: error: expected initializer before numeric constant
#define maxn 5001;
^
/in/foo.cc:5:12: note: in expansion of macro 'maxn'
int father maxn;
^~~~
/in/foo.cc: In function 'int find(int)':
/in/foo.cc:9:5: error: 'father' was not declared in this scope
if(father[x]!=x)
^~~~~~
/in/foo.cc:10:32: error: expected ',' before '[' token
return father[x]=find([father[x]);
^
/in/foo.cc:10:32: error: expected identifier before '[' token
/in/foo.cc:10:36: error: expected ']' before ';' token
return father[x]=find([father[x]);
^
/in/foo.cc: In lambda function:
/in/foo.cc:10:36: error: expected '{' before ';' token
/in/foo.cc: In function 'int find(int)':
/in/foo.cc:10:36: error: expected ')' before ';' token
/in/foo.cc: In function 'void con(int, int)':
/in/foo.cc:14:2: error: 'father' was not declared in this scope
father[l2]=l1;
^~~~~~
/in/foo.cc: In function 'int main()':
/in/foo.cc:18:15: warning: left operand of comma operator has no effect [-Wunused-value]
for(int i=1;i<=n,i++)
~^~~
/in/foo.cc:18:22: error: expected ';' before ')' token
for(int i=1;i<=n,i++)
^
/in/foo.cc:20:3: error: 'father' was not declared in this scope
father[i]=i;
^~~~~~
/in/foo.cc:34:18: error: 'ptintf' was not declared in this scope
ptintf("Yes\n");
^