# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
383771 | wind_reaper | Examination (JOI19_examination) | C++17 | 222 ms | 7644 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;
struct BIT{
vector<int> tree;
int N;
BIT(int _n){
N = _n;
tree.resize(N+1);
}
void upd(int pos, int val){
for(++pos; pos <= N; pos += (pos & (-pos)))
tree[pos] += val;
}
int que(int idx){
int sum = 0;
for(idx++; idx > 0; idx -= (idx & (-idx)))
sum += tree[idx];
return sum;
}
};
int32_t main(){
ios_base::sync_with_stdio(false);
cin.tie(NULL);
int n, q;
cin >> n >> q;
# | 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... |