# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
741810 | jamezzz | Advertisement 2 (JOI23_ho_t2) | C++17 | 1135 ms | 132576 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;
#define sf scanf
#define pf printf
#define fi first
#define se second
#define INF 2023456789
typedef pair<int,int> ii;
#define maxn 500005
int n,x[maxn],e[maxn],d[maxn];
vector<int> v;
set<ii> s1;
struct node{
int s,e,m,v;
node *l,*r;
node(int _s,int _e){
s=_s,e=_e,m=(s+e)>>1,v=-INF;
if(s!=e)l=new node(s,m),r=new node(m+1,e);
}
void up(int x,int nv){
if(s==x&&e==x){v=nv;return;}
if(x<=m)l->up(x,nv);
else r->up(x,nv);
v=max(l->v,r->v);
}
int qry(int x,int y){
Compilation message (stderr)
# | 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... |