Submission #926727

#TimeUsernameProblemLanguageResultExecution timeMemory
926727ByeWorld기지국 (IOI20_stations)C++14
8 / 100
607 ms1100 KiB
#include "stations.h" #include <vector> #include <bits/stdc++.h> #define fi first #define se second #define pb push_back using namespace std; typedef pair<int,int> pii; typedef pair<pii,int> ipii; const int MAXN = 2e3+10; int n, k; vector <int> adj[MAXN]; vector<int> label(int N, int K, vector<int> u, vector<int> v) { n = N; k = K; for(int i=0; i<n-1; i++){ adj[u[i]].pb(v[i]); adj[v[i]].pb(u[i]); } vector<int> labels(n); for (int i = 0; i < n; i++) { labels[i] = i+1; } return labels; } int find_next_station(int s, int t, vector<int> c) { if(s < t){ int las = t; while(s < t){ las = t; t /= 2; } if(s==t) return las; // t naik terus return s/2; // s harus naik } // s lebih di bawah return s/2; }
#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...