QOJ.ac
QOJ
ID | Problem | Submitter | Result | Time | Memory | Language | File size | Submit time | Judge time |
---|---|---|---|---|---|---|---|---|---|
#861658 | #1. I/O Test | 12213 | Compile Error | / | / | C++14 | 731b | 2025-01-18 19:03:44 | 2025-01-18 19:03:44 |
Judging History
config.txt
#include<bits/stdc++.h> using namespace std; const int N = 2e5+10; #define int long long map<int,int>mp; int n,t(0),g(0),cnt(1),l,r; int ask(){ while(mp[cnt])cnt++; cout<<"? "<<cnt<<endl; l=cnt+1; mp[cnt]++; cout.flush(); cin>>g; if(g==t)return 1; t=g; return 0; } signed main(){ cin>>n; l=1,r=n; if(ask()){ cout<<"! "<<cnt<<endl; return 0; } while(1){ cout<<"? "<<(l+r>>1)<<endl; cout.flush(); cin>>g; // cout<<g<<" "<<t<<endl; if(g>t){ l ...
input_test
output_test
Details
Invalid Configuration File: failed to read Nin and Nout