# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
526378 | Alex_tz307 | Bubble Sort 2 (JOI18_bubblesort2) | C++17 | 2096 ms | 38372 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 "bubblesort2.h"
#define INF 0x3f3f3f3f
using namespace std;
struct ST {
int n;
vector<int> t, lazy;
ST(int N) : n(N) {
int dim = 1;
while (dim < n) {
dim *= 2;
}
dim *= 2;
t.resize(dim, -INF);
lazy.resize(dim);
}
void updateNode(int x, int v) {
t[x] += v;
lazy[x] += v;
}
void push(int x) {
if (lazy[x] == 0) {
return;
}
for (int i = 0; i < 2; ++i) {
# | 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... |