Submission #302149

#TimeUsernameProblemLanguageResultExecution timeMemory
302149TMJNThe Big Prize (IOI17_prize)C++17
20 / 100
1 ms384 KiB
#include "prize.h" #include <bits/stdc++.h> using namespace std; int find_best(int n) { int l,r; l=-1; r=n; while(l+1!=r){ int m=(l+r)/2; vector<int>a=ask(m); if(a[0]==0&&a[1]==0)return m; if(a[0]){ r=m; } else{ l=m; } } return -1; }
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...