제출 #382969

#제출 시각아이디문제언어결과실행 시간메모리
382969AlmaFinding Routers (IOI20_routers)C++14
0 / 100
1 ms492 KiB
#include <bits/stdc++.h> #include "routers.h" using namespace std; vector<int> find_routers(int l, int n, int q) { int lo = 0, hi = l, mid, res = 0; while (lo <= hi) { mid = lo + (hi-lo) / 2; if (use_detector(mid) == 0) { res = mid; hi = mid-1; } else { lo = mid+1; } } vector<int> ans; if (res == 0) { ans = {0, 1}; } else { ans = {0, 2*res-1}; } return ans; }
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...