# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
919839 | Macker | Wall (IOI14_wall) | C++17 | 598 ms | 86104 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 <wall.h>
#include <bits/stdc++.h>
using namespace std;
typedef long long ll;
#define all(v) v.begin(), v.end()
#define smin(a, b) a = min(a, b)
#define smax(a, b) a = max(a, b)
struct node{
int mx = INT_MAX, mn = 0;
int val = 0;
};
vector<node> st;
int len = 1;
void prop(int i){
node& n = st[i], &l = st[i * 2], &r = st[i * 2 + 1];
smin(l.mx, n.mx); smax(l.mx, n.mn);
smax(l.mn, n.mn); smin(l.mn, n.mx);
smin(l.val, n.mx); smax(l.val, n.mn);
smin(r.mx, n.mx); smax(r.mx, n.mn);
smax(r.mn, n.mn); smin(r.mn, n.mx);
smin(r.val, n.mx); smax(r.val, n.mn);
n.mx = INT_MAX;
n.mn = 0;
}
# | 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... |