# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
916713 | Dec0Dedd | Fortune Telling 2 (JOI14_fortune_telling2) | C++14 | 5 ms | 14424 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;
typedef long long ll;
typedef pair<int, int> pii;
typedef pair<int, pii> pp;
const int N = 2e5+10;
const int X = 3*N;
int x[N], y[N], a[N], b[N], t[N], n, k;
struct segtree {
vector<int> t;
void init(int sz) {
t.resize(4*sz+1);
}
void upd(int v, int l, int r, int p, int vl) {
if (l == r) {
t[v]=max(vl, t[v]);
return;
} int m=(l+r)/2;
if (p <= m) upd(2*v, l, m, p, vl);
else upd(2*v+1, m+1, r, p, vl);
t[v]=max(t[2*v], t[2*v+1]);
}
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |