# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
532310 | gg123_pe | ICC (CEOI16_icc) | C++14 | 6 ms | 460 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>
#include "icc.h"
using namespace std;
typedef pair<int,int> ii;
#define f(i,a,b) for(int i = a; i < b; i++)
#define ff first
#define ss second
int n, p[105], a[105], b[105];
vector <int> adj[105], parents;
void divide(vector <ii> v1, vector <ii> v2, vector <ii> &a1, vector <ii> &a2){
for(auto p: v1){
int l = p.ff, r = p.ss, sz = r-l+1;
if(sz > 1) a1.push_back({l, l+sz/2-1}), a2.push_back({l+sz/2, r});
else a1.push_back({l, r});
}
for(auto p: v2){
int l = p.ff, r = p.ss, sz = r-l+1;
if(sz > 1) a1.push_back({l, l+sz/2-1}), a2.push_back({l+sz/2, r});
else a1.push_back({l, r});
}
}
vector <int> get(vector <ii> v){
vector <int> ra;
for(auto p: v){
int l = p.ff, r = p.ss;
f(i,l,r+1) for(int x: adj[parents[i]]) ra.push_back(x);
# | 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... |