Submission #255197

#TimeUsernameProblemLanguageResultExecution timeMemory
255197a_playerGuess the number (BOI20_guess)C++14
0 / 100
3086 ms256 KiB
#include <bits/stdc++.h> using namespace std; bool check(int t){ cout<<"? "<<t<<endl; int h; cin>>h; return h<1; } int main(){ int N; cin>>N; int x=-1; for(int b=N;b>=1;b/=2) while(check(x+b))x+=b; cout<<"= "<<x; }
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...