제출 #1186976

#제출 시각아이디문제언어결과실행 시간메모리
1186976hengliao기지국 (IOI20_stations)C++20
0 / 100
306 ms440 KiB
#include "stations.h" #include<bits/stdc++.h> using namespace std; #define F first #define S second #define vll vector<ll> #define pll pair<ll, ll> #define pb push_back typedef int ll; vector<int> label(int n, int k, vector<int> u, vector<int> v) { vll re(n); for(ll i=0;i<n;i++){ re[i]=i+1; } return re; } int find_next_station(int s, int t, vector<int> c) { vll con; while(t>0){ con.pb(t); t/=2; } ll p=s/2; for(auto &it:c){ if(it==p) continue; auto it2=lower_bound(con.begin(), con.end(), it); if(it2!=con.end() && (*it2)==it){ return it; } } return p; }
#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...