# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
559697 | SSRS | Land of the Rainbow Gold (APIO17_rainbow) | C++14 | 9 ms | 1108 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;
int xmin, xmax, ymin, ymax;
struct range_tree{
int N;
vector<vector<int>> ST;
range_tree(){
}
range_tree(int N2){
N = 1;
while (N < N2){
N *= 2;
}
ST = vector<vector<int>>(N * 2 - 1);
}
void add(int X, int Y){
X += N - 1;
ST[X].push_back(Y);
while (X > 0){
X = (X - 1) / 2;
ST[X].push_back(Y);
}
}
void build(){
for (int i = 0; i < N * 2 - 1; i++){
sort(ST[i].begin(), ST[i].end());
}
}
int rectangle_sum(int L, int R, int U, int D, int i, int l, int r){
# | 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... |