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;
int tree[200005];
int n;
void update(int i, int x){
i += n;
while(i > 0){
tree[i] += x;
i >>= 1;
}
}
int query(int l, int r){
int ans = 0;
for(l += n,r += n;l < r;l >>= 1, r >>= 1){
if(l&1){
ans += tree[l];
l++;
}
if(r&1){
r--;
ans += tree[r];
}
}
return ans;
}
int tree2[200005];
int GetBestPosition(int N, int C, int R, int *K, int *S, int *E) {
return 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... |