wall.cpp:23:1: error: 'vector' does not name a type
23 | vector <point> t(4 * MAX, {0, 0}), lazy(4 * MAX, {-1, INF});
| ^~~~~~
wall.cpp:23:33: error: expected unqualified-id before ')' token
23 | vector <point> t(4 * MAX, {0, 0}), lazy(4 * MAX, {-1, INF});
| ^
wall.cpp:23:59: error: expected unqualified-id before ')' token
23 | vector <point> t(4 * MAX, {0, 0}), lazy(4 * MAX, {-1, INF});
| ^
wall.cpp:24:1: error: 'vector' does not name a type
24 | vector <int> h;
| ^~~~~~
wall.cpp: In function 'void push(int)':
wall.cpp:27:13: error: 'lazy' was not declared in this scope
27 | if (lazy[v].ma != -1) {
| ^~~~
wall.cpp:28:21: error: 't' was not declared in this scope
28 | if (t[v*2].mi < lazy[v].ma) {
| ^
wall.cpp:30:37: error: 'max' was not declared in this scope; did you mean 'std::max'?
30 | t[v*2].ma = max(t[v*2].ma, t[v*2].mi);
| ^~~
| std::max
In file included from /usr/include/c++/11/algorithm:62,
from /usr/include/x86_64-linux-gnu/c++/11/bits/stdc++.h:65,
from wall.cpp:2:
/usr/include/c++/11/bits/stl_algo.h:3467:5: note: 'std::max' declared here
3467 | max(initializer_list<_Tp> __l, _Compare __comp)
| ^~~
wall.cpp:33:21: error: 't' was not declared in this scope
33 | if (t[v*2+1].mi < lazy[v].ma) {
| ^
wall.cpp:35:39: error: 'max' was not declared in this scope; did you mean 'std::max'?
35 | t[v*2+1].ma = max(t[v*2+1].ma, t[v*2+1].mi);
| ^~~
| std::max
In file included from /usr/include/c++/11/algorithm:62,
from /usr/include/x86_64-linux-gnu/c++/11/bits/stdc++.h:65,
from wall.cpp:2:
/usr/include/c++/11/bits/stl_algo.h:3467:5: note: 'std::max' declared here
3467 | max(initializer_list<_Tp> __l, _Compare __comp)
| ^~~
wall.cpp:40:13: error: 'lazy' was not declared in this scope
40 | if (lazy[v].mi != INF) {
| ^~~~
wall.cpp:41:21: error: 't' was not declared in this scope
41 | if (t[v*2].ma > lazy[v].mi) {
| ^
wall.cpp:43:37: error: 'min' was not declared in this scope; did you mean 'std::min'?
43 | t[v*2].mi = min(t[v*2].mi, t[v*2].ma);
| ^~~
| std::min
In file included from /usr/include/c++/11/algorithm:62,
from /usr/include/x86_64-linux-gnu/c++/11/bits/stdc++.h:65,
from wall.cpp:2:
/usr/include/c++/11/bits/stl_algo.h:3455:5: note: 'std::min' declared here
3455 | min(initializer_list<_Tp> __l, _Compare __comp)
| ^~~
wall.cpp:46:21: error: 't' was not declared in this scope
46 | if (t[v*2+1].ma > lazy[v].mi) {
| ^
wall.cpp:48:39: error: 'min' was not declared in this scope; did you mean 'std::min'?
48 | t[v*2+1].mi = min(t[v*2+1].mi, t[v*2+1].ma);
| ^~~
| std::min
In file included from /usr/include/c++/11/algorithm:62,
from /usr/include/x86_64-linux-gnu/c++/11/bits/stdc++.h:65,
from wall.cpp:2:
/usr/include/c++/11/bits/stl_algo.h:3455:5: note: 'std::min' declared here
3455 | min(initializer_list<_Tp> __l, _Compare __comp)
| ^~~
wall.cpp: In function 'void update1(int, int, int, int, int, int)':
wall.cpp:58:21: error: 't' was not declared in this scope
58 | if (t[v].mi < x) {
| ^
wall.cpp:59:25: error: 'lazy' was not declared in this scope
59 | lazy[v].ma = max(lazy[v].ma, x);
| ^~~~
wall.cpp:59:38: error: 'max' was not declared in this scope; did you mean 'std::max'?
59 | lazy[v].ma = max(lazy[v].ma, x);
| ^~~
| std::max
In file included from /usr/include/c++/11/algorithm:62,
from /usr/include/x86_64-linux-gnu/c++/11/bits/stdc++.h:65,
from wall.cpp:2:
/usr/include/c++/11/bits/stl_algo.h:3467:5: note: 'std::max' declared here
3467 | max(initializer_list<_Tp> __l, _Compare __comp)
| ^~~
wall.cpp:67:32: error: 'min' was not declared in this scope; did you mean 'std::min'?
67 | update(v*2, tl, tm, l, min(r, tm), x);
| ^~~
| std::min
In file included from /usr/include/c++/11/algorithm:62,
from /usr/include/x86_64-linux-gnu/c++/11/bits/stdc++.h:65,
from wall.cpp:2:
/usr/include/c++/11/bits/stl_algo.h:3455:5: note: 'std::min' declared here
3455 | min(initializer_list<_Tp> __l, _Compare __comp)
| ^~~
wall.cpp:67:9: error: 'update' was not declared in this scope; did you mean 'update1'?
67 | update(v*2, tl, tm, l, min(r, tm), x);
| ^~~~~~
| update1
wall.cpp:68:33: error: 'max' was not declared in this scope; did you mean 'std::max'?
68 | update(v*2+1, tm+1, tr, max(l, tm+1), r, x);
| ^~~
| std::max
In file included from /usr/include/c++/11/algorithm:62,
from /usr/include/x86_64-linux-gnu/c++/11/bits/stdc++.h:65,
from wall.cpp:2:
/usr/include/c++/11/bits/stl_algo.h:3467:5: note: 'std::max' declared here
3467 | max(initializer_list<_Tp> __l, _Compare __comp)
| ^~~
wall.cpp:69:9: error: 't' was not declared in this scope; did you mean 'tm'?
69 | t[v].ma = max(t[v*2].ma, t[v*2+1].ma);
| ^
| tm
wall.cpp: In function 'void update2(int, int, int, int, int, int)':
wall.cpp:76:21: error: 't' was not declared in this scope
76 | if (t[v].ma > x) {
| ^
wall.cpp:77:25: error: 'lazy' was not declared in this scope
77 | lazy[v].mi = min(lazy[v].mi, x);
| ^~~~
wall.cpp:77:38: error: 'min' was not declared in this scope; did you mean 'std::min'?
77 | lazy[v].mi = min(lazy[v].mi, x);
| ^~~
| std::min
In file included from /usr/include/c++/11/algorithm:62,
from /usr/include/x86_64-linux-gnu/c++/11/bits/stdc++.h:65,
from wall.cpp:2:
/usr/include/c++/11/bits/stl_algo.h:3455:5: note: 'std::min' declared here
3455 | min(initializer_list<_Tp> __l, _Compare __comp)
| ^~~
wall.cpp:79:35: error: 'max' was not declared in this scope; did you mean 'std::max'?
79 | t[v].mi = max(t[v].ma, t[v].mi);
| ^~~
| std::max
In file included from /usr/include/c++/11/algorithm:62,
from /usr/include/x86_64-linux-gnu/c++/11/bits/stdc++.h:65,
from wall.cpp:2:
/usr/include/c++/11/bits/stl_algo.h:3467:5: note: 'std::max' declared here
3467 | max(initializer_list<_Tp> __l, _Compare __comp)
| ^~~
wall.cpp:85:32: error: 'min' was not declared in this scope; did you mean 'std::min'?
85 | update(v*2, tl, tm, l, min(r, tm), x);
| ^~~
| std::min
In file included from /usr/include/c++/11/algorithm:62,
from /usr/include/x86_64-linux-gnu/c++/11/bits/stdc++.h:65,
from wall.cpp:2:
/usr/include/c++/11/bits/stl_algo.h:3455:5: note: 'std::min' declared here
3455 | min(initializer_list<_Tp> __l, _Compare __comp)
| ^~~
wall.cpp:85:9: error: 'update' was not declared in this scope; did you mean 'update2'?
85 | update(v*2, tl, tm, l, min(r, tm), x);
| ^~~~~~
| update2
wall.cpp:86:33: error: 'max' was not declared in this scope; did you mean 'std::max'?
86 | update(v*2+1, tm+1, tr, max(l, tm+1), r, x);
| ^~~
| std::max
In file included from /usr/include/c++/11/algorithm:62,
from /usr/include/x86_64-linux-gnu/c++/11/bits/stdc++.h:65,
from wall.cpp:2:
/usr/include/c++/11/bits/stl_algo.h:3467:5: note: 'std::max' declared here
3467 | max(initializer_list<_Tp> __l, _Compare __comp)
| ^~~
wall.cpp:87:9: error: 't' was not declared in this scope; did you mean 'tm'?
87 | t[v].ma = max(t[v*2].ma, t[v*2+1].ma);
| ^
| tm
wall.cpp: In function 'void build(int, int, int)':
wall.cpp:93:17: error: 'h' was not declared in this scope
93 | h.pb(t[v]);
| ^
wall.cpp:93:22: error: 't' was not declared in this scope
93 | h.pb(t[v]);
| ^
wall.cpp: In function 'void buildWall(int, int, int*, int*, int*, int*, int*)':
wall.cpp:110:15: error: invalid conversion from 'int*' to 'int' [-fpermissive]
110 | build(finalHeight);
| ^~~~~~~~~~~
| |
| int*
wall.cpp:110:14: error: too few arguments to function 'void build(int, int, int)'
110 | build(finalHeight);
| ~~~~~^~~~~~~~~~~~~
wall.cpp:91:6: note: declared here
91 | void build(int v, int tl, int tr) {
| ^~~~~