# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
774240 | NintsiChkhaidze | Hedgehog Daniyar and Algorithms (IZhO19_sortbooks) | C++17 | 2573 ms | 100388 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 ll long long
#define pb push_back
#define s second
#define f first
#define pll pair <ll,ll>
#define pii pair <int,int>
#define left h*2,l,(l + r)/2
#define right h*2+1,(l + r)/2 + 1,r
#define int ll
using namespace std;
const int N = 1e6 + 5,inf = 1e9;
int a[N],le[N],ri[N],ans[N],k[N];
int t[4*N];
vector <int> v[N];
void upd(int h,int l,int r,int idx,int val){
if (l == r){
t[h] = max(t[h],val);
return;
}
int mid = (l + r)/2;
if (idx > mid) upd(right,idx,val);
else upd(left,idx,val);
t[h] = max(t[h*2],t[h*2 + 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... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |