souvenirs.cpp:1:1: error: expected unqualified-id before '>' token
1 | >
| ^
souvenirs.cpp:35:6: error: 'vector' was not declared in this scope
35 | pair<vector<int>, long long> transaction(long long M);
| ^~~~~~
souvenirs.cpp:35:6: error: 'vector' was not declared in this scope
souvenirs.cpp:35:6: error: 'vector' was not declared in this scope
souvenirs.cpp:35:6: error: 'vector' was not declared in this scope
souvenirs.cpp:35:6: error: 'vector' was not declared in this scope
souvenirs.cpp:35:6: error: 'vector' was not declared in this scope
souvenirs.cpp:35:6: error: 'vector' was not declared in this scope
souvenirs.cpp:35:6: error: 'vector' was not declared in this scope
souvenirs.cpp:35:6: error: 'vector' was not declared in this scope
souvenirs.cpp:35:1: error: 'pair' does not name a type
35 | pair<vector<int>, long long> transaction(long long M);
| ^~~~
souvenirs.cpp: In function 'void buy_souvenirs(int, long long int)':
souvenirs.cpp:38:5: error: 'vector' was not declared in this scope
38 | vector<ll> minP(N); iota(rall(minP), 1);
| ^~~~~~
souvenirs.cpp:38:14: error: expected primary-expression before '>' token
38 | vector<ll> minP(N); iota(rall(minP), 1);
| ^
souvenirs.cpp:38:16: error: 'minP' was not declared in this scope
38 | vector<ll> minP(N); iota(rall(minP), 1);
| ^~~~
souvenirs.cpp:8:17: error: 'rbegin' was not declared in this scope
8 | #define rall(x) rbegin(x),rend(x)
| ^~~~~~
souvenirs.cpp:38:30: note: in expansion of macro 'rall'
38 | vector<ll> minP(N); iota(rall(minP), 1);
| ^~~~
souvenirs.cpp:8:27: error: 'rend' was not declared in this scope; did you mean 'friend'?
8 | #define rall(x) rbegin(x),rend(x)
| ^~~~
souvenirs.cpp:38:30: note: in expansion of macro 'rall'
38 | vector<ll> minP(N); iota(rall(minP), 1);
| ^~~~
souvenirs.cpp:38:25: error: 'iota' was not declared in this scope
38 | vector<ll> minP(N); iota(rall(minP), 1);
| ^~~~
souvenirs.cpp:39:14: error: expected primary-expression before '>' token
39 | vector<ll> maxP(N); iota(rall(maxP), P0 - (N - 1));
| ^
souvenirs.cpp:39:16: error: 'maxP' was not declared in this scope
39 | vector<ll> maxP(N); iota(rall(maxP), P0 - (N - 1));
| ^~~~
souvenirs.cpp:43:12: error: expected primary-expression before 'int'
43 | vector<int> cnt(N);
| ^~~
souvenirs.cpp: In lambda function:
souvenirs.cpp:49:23: error: 'max' was not declared in this scope
49 | minP[v] = max(minP[v], x);
| ^~~
souvenirs.cpp: In lambda function:
souvenirs.cpp:59:23: error: 'min' was not declared in this scope
59 | maxP[v] = min(maxP[v], x);
| ^~~
souvenirs.cpp: In lambda function:
souvenirs.cpp:79:23: error: 'transaction' was not declared in this scope
79 | auto [V, r] = transaction(q);
| ^~~~~~~~~~~
souvenirs.cpp:81:24: error: 'cnt' was not declared in this scope; did you mean 'int'?
81 | for(auto x: V) cnt[x]++;
| ^~~
| int
souvenirs.cpp: In function 'void buy_souvenirs(int, long long int)':
souvenirs.cpp:110:15: error: 'cnt' was not declared in this scope; did you mean 'int'?
110 | while(cnt[i] < i) buy(i);
| ^~~
| int