# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
533082 | new_acc | Jakarta Skyscrapers (APIO15_skyscraper) | C++14 | 259 ms | 262148 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>
#define fi first
#define se second
using namespace std;
typedef long long ll;
typedef vector<int> vi;
typedef vector<ll> vl;
const int N=3e4+10;
vector<pair<int,int> > graf[1000*1000*2+10];
pair<int,int>w[N];
int l,num[N];
vi li[300];
bitset<N>bb;
bitset<1000*1000*2+10>vis;
vi kol[1000*1000*5+10];
int n,m;
void single(int x){
if(li[x].empty()) return;
for(int i=1;i<=x;i++){
num[i]=++l;
graf[l].push_back({i,0});
}
for(int i=x+1;i<=n;i++){
num[i]=++l;
graf[l].push_back({i,0}),graf[l].push_back({num[i-x],1});
}
for(int i=1;i<=n;i++) bb[i]=0;
for(auto u:li[x]) bb[w[u].fi]=1;
for(int i=1;i<=n;i++) if(bb[i]) graf[i].push_back({num[i],0});
for(int i=n;i>=n-x+1;i--){
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... |