# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
796686 | MetalPower | Team Contest (JOI22_team) | C++17 | 321 ms | 26516 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 pii pair<int, int>
#define fi first
#define se second
const int MX = 150069;
const int INF = 1e9 + 7;
int N, arr[MX][3];
vector<int> cc[3];
vector<pii> ls[MX], cm;
set<pii> s;
struct segmax{
int st[MX << 1];
void build(){
for(int i = 0; i < (MX << 1); i++) st[i] = -INF;
}
void upd(int p, int v){
for(p += MX, st[p] = v, p >>= 1; p > 0; p >>= 1) st[p] = max(st[p << 1], st[p << 1|1]);
}
int que(int l, int r){
int res = -INF;
for(l += MX, r += MX + 1; l < r; l >>= 1, r >>= 1){
if(l & 1) res = max(res, st[l++]);
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... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |