Submission #738474

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