# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
600277 | valerikk | Road Construction (JOI21_road_construction) | C++17 | 3309 ms | 648352 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 N = 2.5e5 + 15;
const int INF = 2e9 + 1;
struct node {
node *l, *r;
pair<int, int> mn;
node(node *l_, node *r_, pair<int, int> mn_) : l(l_), r(r_), mn(mn_) {}
};
node *copy(node *t) {
return new node(t->l, t->r, t->mn);
}
node *build(int tl, int tr) {
if (tr - tl == 1) {
return new node(0, 0, {INF, INF});
}
int tm = (tl + tr) / 2;
return new node(build(tl, tm), build(tm, tr), {INF, INF});
}
pair<int, int> get(node *t, int tl, int tr, int l, int r) {
if (tl >= r || tr <= l) {
return {INF, INF};
}
# | 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... |