eastereggs.cpp:5:15: error: 'vector' has not been declared
5 | int dfs(int n,vector<int>v[513],int idx=1){
| ^~~~~~
eastereggs.cpp:5:21: error: expected ',' or '...' before '<' token
5 | int dfs(int n,vector<int>v[513],int idx=1){
| ^
eastereggs.cpp: In function 'int dfs(int, int)':
eastereggs.cpp:6:9: error: 'idx' was not declared in this scope
6 | vis[idx]=1;
| ^~~
eastereggs.cpp:8:19: error: 'v' was not declared in this scope
8 | for(int i=0;i<v[idx].size();i++){
| ^
eastereggs.cpp: At global scope:
eastereggs.cpp:15:1: error: 'vector' does not name a type
15 | vector<int> dfs2(int n,vector<int>v[513],int idx=1){
| ^~~~~~
eastereggs.cpp:29:21: error: 'vector' has not been declared
29 | int findEgg (int n, vector<pair<int,int> > edg){
| ^~~~~~
eastereggs.cpp:29:27: error: expected ',' or '...' before '<' token
29 | int findEgg (int n, vector<pair<int,int> > edg){
| ^
eastereggs.cpp: In function 'int findEgg(int, int)':
eastereggs.cpp:30:5: error: 'memset' was not declared in this scope
30 | memset(vis,0,sizeof vis);
| ^~~~~~
eastereggs.cpp:1:1: note: 'memset' is defined in header '<cstring>'; did you forget to '#include <cstring>'?
+++ |+#include <cstring>
1 | #define pb push_back
eastereggs.cpp:32:5: error: 'vector' was not declared in this scope
32 | vector<int> v[513];
| ^~~~~~
eastereggs.cpp:32:12: error: expected primary-expression before 'int'
32 | vector<int> v[513];
| ^~~
eastereggs.cpp:33:19: error: 'edg' was not declared in this scope
33 | for(int i=0;i<edg.size();i++){
| ^~~
eastereggs.cpp:34:9: error: 'v' was not declared in this scope
34 | v[edg[i].f].pb(edg[i].s);
| ^
eastereggs.cpp:39:11: error: 'v' was not declared in this scope
39 | dfs(n,v,1);
| ^
eastereggs.cpp:44:16: error: expected primary-expression before 'int'
44 | vector<int> h;
| ^~~
eastereggs.cpp:47:17: error: 'h' was not declared in this scope
47 | h.pb(i);
| ^
eastereggs.cpp:54:12: error: 'h' was not declared in this scope
54 | if(h.size()==1){
| ^
eastereggs.cpp:55:24: error: 'query' was not declared in this scope
55 | if(bol==0&&query(h)==0)
| ^~~~~
eastereggs.cpp:66:16: error: expected primary-expression before 'int'
66 | vector<int> va,vb;
| ^~~
eastereggs.cpp:67:9: error: 'vb' was not declared in this scope; did you mean 'b'?
67 | vb.pb(x);
| ^~
| b
eastereggs.cpp:74:24: error: expected primary-expression before 'int'
74 | vector<int> z=dfs2(n,v,v[x][i]);
| ^~~
eastereggs.cpp:75:31: error: 'z' was not declared in this scope
75 | for(int j=0;j<z.size();j++){
| ^
eastereggs.cpp:85:17: error: 'va' was not declared in this scope; did you mean 'a'?
85 | va.pb(i);
| ^~
| a
eastereggs.cpp:96:12: error: 'query' was not declared in this scope
96 | if(query(vb)){
| ^~~~~
eastereggs.cpp:112:32: error: 'va' was not declared in this scope; did you mean 'a'?
112 | else if((bol==0&&query(va))||bol==1){
| ^~
| a