# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
115120 | sebinkim | 무지개나라 (APIO17_rainbow) | C++14 | 514 ms | 307496 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>
#include "rainbow.h"
using namespace std;
typedef pair <int, int> pii;
struct pst{
struct node{
int l, r, v;
node() : l(0), r(0), v(0) {}
};
node T[10101010];
int R[202020], r, t, c;
void init(int w) { c = w; }
void insert(int p, int s, int e, int i, int v)
{
T[p].v += v;
if(s == e) return;
else if(i <= (s + e >> 1)){
T[++t] = T[T[p].l]; T[p].l = t;
insert(T[p].l, s, s + e >> 1, i, v);
}
else{
T[++t] = T[T[p].r]; T[p].r = t;
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... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |