# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
1133533 | Muhammet | Segments (IZhO18_segments) | C++17 | 2570 ms | 58028 KiB |
#include "bits/stdc++.h"
using namespace std;
#define SZ(s) (int)s.size()
#define ff first
#define ss second
const int N = 2e5 + 5;
int st[N*4], stm[N*4];
vector <vector <int>> vc[2][2];
vector <pair<int,int>> v[2];
vector <pair<int,pair<int,int>>> s[2];
int bld(int nd, int l, int r, int t){
if(l == r){
st[nd] = s[t][l].ff;
stm[nd] = s[t][l].ff;
vc[t][0][nd].push_back(s[t][l].ss.ff);
vc[t][1][nd].push_back(s[t][l].ss.ss);
return st[nd];
}
int md = (l + r) / 2;
st[nd] = min(bld(nd*2,l,md,t), bld(nd*2+1,md+1,r,t));
stm[nd] = max(stm[nd*2], stm[nd*2+1]);
vector <int> v1 = vc[t][0][nd*2], v2 = vc[t][0][nd*2+1];
# | 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... |