# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
739447 | Mauve | Jakarta Skyscrapers (APIO15_skyscraper) | C++17 | 1083 ms | 241652 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 ll int
#define ss second
#define ff first
#define INF 2000000000000000
#define pb push_back
#define edge pair<ll, pair<ll,ll> > // une, number ,power
#define cost first
#define num second.first
#define pwr second.second
ll n,m,l,r,i,j,ii,jj,k,x,y,D[30001][179],s,e;
vector< edge > v[30001][177]; // number , power (powergu oroi bol power = 179)
int main(){
ios::sync_with_stdio(false);
cin.tie(nullptr);
cout.tie(nullptr);
cin>>n>>m;
for(i=1;i<=m;i++){
cin>>l>>r;
if(i==1) s=l;
if(i==2) e=l;
if(r>175)
for(j=1 ; l+r*j<n || l-r*j>=0 ; j++){
edge a;
a.num=l+r*j;
a.pwr=176;
a.cost=j;
if(a.num<n) v[l][176].pb(a);
a.num=l-r*j;
# | 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... |