# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
1042662 | BF001 | Bubble Sort 2 (JOI18_bubblesort2) | C++17 | 1436 ms | 55460 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 N 1000005
#define fi first
#define se second
typedef pair<int, int> ii;
int bit[4 * N], lazy[4 * N];
vector<ii> vec;
void add(int id, int val){
bit[id] += val;
lazy[id] += val;
}
void down(int id, int l, int r){
if (l == r) return;
add(id * 2, lazy[id]);
add(id * 2 + 1, lazy[id]);
lazy[id] = 0;
}
void ud(int id, int l, int r, int u, int v, int val){
if (l > v || r < u) return;
if (l >= u && r <= v){
add(id, val);
return;
}
# | 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... |