# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
1013729 | vjudge1 | Bubble Sort 2 (JOI18_bubblesort2) | C++17 | 33 ms | 3480 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 "bubblesort2.h"
#include <bits/stdc++.h>
using namespace std;
using ll = long long;
using vll = vector <ll>;
using vi = vector <int>;
// using ii = pair <ll, ll>;
// using vii = vector <ii>;
const ll MAXN = 1E4+16, INF = ll(1E18)+16;
priority_queue <ll> pq[MAXN];
struct Fenwick {
vll tree;
ll n;
Fenwick (ll n): tree(n, 0), n(n) {}
void update (ll id, ll val) {
for (; id < n; id |= id+1) tree[id] += val;
}
ll query (ll id) {
ll ans = 0;
for (; id >= 0; id &= id+1, id--) ans += tree[id];
return ans;
}
};
struct SegTree {
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... |