# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
114154 | Shtef | Krave (COI14_krave) | C++14 | 1233 ms | 67360 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 <iostream>
#include <set>
using namespace std;
typedef long long ll;
struct node{
set <int> s;
};
int a, b, n, di;
node t[2][(1 << 18) + 5];
ll res;
const ll inf = (ll) 1e18;
void update(int root, int l, int r, int s, int e, int val){
if(l > r || l > e || r < s)
return;
if(l >= s && r <= e){
t[di][root].s.insert(val);
return;
}
int mid = (l + r) / 2;
update(root * 2, l, mid, s, e, val);
update(root * 2 + 1, mid + 1, r, s, e, val);
}
void query(int root, int l, int r, int idx, int val, bool type){
if(l > r || l > idx || r < idx)
# | 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... |
# | 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... |