# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
37401 | HardNut | Divide and conquer (IZhO14_divide) | C++14 | 386 ms | 6864 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<iostream>
#include<cstdio>
using namespace std;
const int N = 1e5 + 5;
typedef long long ll;
ll ans, n, x[N], g[N], e[N];
ll t[N];
ll dpp[N], dp[N];
void build(int v, int L, int R) {
if (L == R) {
t[v] = dpp[L - 1] - x[L];
return;
}
int md = (L + R) >> 1;
build(v * 2, L, md);
build(v * 2 + 1, md + 1, R);
t[v] = min(t[v * 2], t[v * 2 + 1]);
}
ll get(int v, int L, int R, int l, int r) {
if (L > r || l > R)
return 1e9 + 5;
if (l <= L && R <= r)
return t[v];
int md = (L + R) >> 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... |