結果
| 問題 | 
                            No.3212 SUPER Guess the Number
                             | 
                    
| コンテスト | |
| ユーザー | 
                             | 
                    
| 提出日時 | 2025-07-25 22:22:06 | 
| 言語 | C++17  (gcc 13.3.0 + boost 1.87.0)  | 
                    
| 結果 | 
                             
                                WA
                                 
                             
                            
                         | 
                    
| 実行時間 | - | 
| コード長 | 314 bytes | 
| コンパイル時間 | 2,334 ms | 
| コンパイル使用メモリ | 194,992 KB | 
| 実行使用メモリ | 26,228 KB | 
| 平均クエリ数 | 22.00 | 
| 最終ジャッジ日時 | 2025-07-25 22:22:12 | 
| 合計ジャッジ時間 | 4,567 ms | 
| 
                            ジャッジサーバーID (参考情報)  | 
                        judge3 / judge5 | 
(要ログイン)
| ファイルパターン | 結果 | 
|---|---|
| other | WA * 12 | 
ソースコード
#include<bits/stdc++.h>
using namespace std;
int main(){
  int l=1,r=1e6+1;
  cout<<"? "<<l<<endl;
  bool f=true;
  while(r-l>1){
    cout<<"? "<<(f?r:l)<<endl;
    int ret;
    cin>>ret;
    if(ret){
      l=(l+r)/2;
      f=false;
    }
    else{
      r=(l+r)/2;
      f=true;
    }
  }
  cout<<"! "<<l<<endl;
}