Submission #138765

#TimeUTC-0UsernameProblemLanguageResultExecution timeMemory
1387652019-07-30 10:02:14MoNsTeR_CuBeSeats (IOI18_seats)C++17
5 / 100
4074 ms87160 KiB
#include "seats.h"
#include <bits/stdc++.h>
using namespace std;
inline int min(int &a, int &b){
if(a < b) return a;
return b;
}
inline int max(int &a, int &b){
if(a < b) return b;
return a;
}
vector< pair<int, int > > mini;
vector< pair<int, int > > maxi;
void update(int root){
mini[root].first = min(mini[root<<1].first, mini[root<<1|1].first);
mini[root].second = min(mini[root<<1].second, mini[root<<1|1].second);
maxi[root].first = max(maxi[root<<1].first, maxi[root<<1|1].first);
maxi[root].second = max(maxi[root<<1].second, maxi[root<<1|1].second);
}
vector< pair<int, int> > v;
void Build(int root, int left, int right){
if(left == right){
maxi[root].second = mini[root].second = v[left-1].second;
maxi[root].first = mini[root].first = v[left-1].first;
 
הההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההה
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...