Problem sealevel
User chickengoat
Submission Time 2026-04-25 11:18:24
Score 0
Max Time N/A
Max Memory N/A

Compile Error

sealevel.cpp:5:17: error: array bound is not an integer constant before ‘]’ token
5 | bool visited[n+1];
| ^
sealevel.cpp:6:1: error: ‘height’ does not name a type
6 | height[n+1];
| ^~~~~~
sealevel.cpp: In function ‘void dfs(ll)’:
sealevel.cpp:8:5: error: ‘visited’ was not declared in this scope
8 | if(visited[x]) return;
| ^~~~~~~
sealevel.cpp:9:2: error: ‘visited’ was not declared in this scope
9 | visited[x]=true;
| ^~~~~~~
sealevel.cpp:10:13: error: ‘adjlist’ was not declared in this scope
10 | for(auto i:adjlist[x]) {
| ^~~~~~~
sealevel.cpp:11:3: error: ‘height’ was not declared in this scope
11 | height[i.first]=height[x]+i.second;
| ^~~~~~
sealevel.cpp: In function ‘int main()’:
sealevel.cpp:22:10: error: wrong number of template arguments (1, should be 2)
22 | pair<ll> p={b,h};
| ^
In fi