Submission #428733

#TimeUsernameProblemLanguageResultExecution timeMemory
428733vanicThe Big Prize (IOI17_prize)C++14
20 / 100
135 ms1460 KiB
#include "prize.h" #include <iostream> #include <algorithm> #include <cmath> #include <vector> using namespace std; int nadji(int L, int D, int vall, int vald){ int mid=(L+D)/2; vector < int > a=ask(mid); if(!a[0] && !a[1]){ return mid; } if(a[0]){ return nadji(L, mid, vall, vald); } return nadji(mid+1, D, vall, vald); } int find_best(int n){ return nadji(0, n, 0, 0); }
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...