# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
253726 | kimbj0709 | Ball Machine (BOI13_ballmachine) | C++14 | 790 ms | 43132 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 int long long
#define maxn 100050
vector<vector<int> > adj(maxn);
vector<int> mini(maxn,-1);
vector<int> fenwick(maxn,0);
vector<int> num(maxn,0);
vector<int> ipos(maxn,0);
#define f first
#define s second
int parents[18][maxn];
void add(int a){
int pos = a+1;
while(pos<fenwick.size()){
fenwick[pos] += 1;
pos += pos&(-pos);
}
return;
}
void add2(int a){
int pos = a+1;
while(pos<fenwick.size()){
fenwick[pos] -= 1;
pos += pos&(-pos);
}
return;
}
int query(int a,int b){
int sum = 0;
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... |