# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
1012861 | fryingduc | Triple Jump (JOI19_jumps) | C++17 | 509 ms | 57772 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"
using namespace std;
const int maxn = 5e5 + 5;
const int inf = 1e9;
int n, q, a[maxn];
vector<pair<int, int>> cand;
int ans[maxn];
struct node {
int res, ft, se;
node() {
res = ft = se = 0;
}
node(int x, int y, int z) : res(x), ft(y), se(z) {}
node operator+(const node &o) const {
node tmp = *this;
tmp.res = max({tmp.res, o.res, this->ft + o.se});
tmp.se = max(tmp.se, o.se);
tmp.ft = max(tmp.ft, o.ft);
return tmp;
}
} tree[maxn * 4];
struct segment_tree {
int n;
segment_tree() {}
segment_tree(int n) : n(n) {}
void build(int ind, int l, int r) {
# | 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... |