# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
711311 | kostia244 | Team Contest (JOI22_team) | C++17 | 185 ms | 15384 KiB |
This submission is migrated from previous version of oj.uz, which used different machine for grading. This submission may have different result if resubmitted.
#include<bits/stdc++.h>
#define all(x) begin(x), end(x)
using namespace std;
using ll = long long;
const int inf = 1<<28;
struct Fenwick {
vector<int> f;
Fenwick(int n) : f(n, -inf) {}
void upd(int pos, int val) {
for(; pos < f.size(); pos += pos & -pos)
f[pos] = max(f[pos], val);
}
int get(int pos) {
int res = -inf;
for(; pos; pos -= pos & -pos)
res = max(res, f[pos]);
return res;
}
};
int main() {
cin.tie(0)->sync_with_stdio(0);
int n;
cin >> n;
vector<array<int, 3>> a(n);
vector<int> Y, yid(n), B(n, inf);
Fenwick A(n + 1);
for(auto &[x, y, z] : a) {
cin >> x >> y >> z;
Compilation message (stderr)
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |