Submission #750320

#TimeUsernameProblemLanguageResultExecution timeMemory
750320mohav48173Stations (IOI20_stations)C++14
8 / 100
960 ms508 KiB
#include "stations.h" #include<bits/stdc++.h> using namespace std; vector<int> label(int n, int k, vector<int> u, vector<int> v) { vector<int>ans; for(int i=0;i<n;i++)ans.push_back(i+1); return ans; } int find_next_station(int s, int t, vector<int> c) { int copyt=t; while(__builtin_clz(t)<__builtin_clz(s)) { t/=2; } if(t!=s)return s/2; t=copyt; while(__builtin_clz(t)+1<__builtin_clz(s))t/=2; if(t%2)return s*2+1; else 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...