結果
| 問題 |
No.3011 あ、俺こいつの役やりたい!
|
| コンテスト | |
| ユーザー |
Shizen
|
| 提出日時 | 2025-01-25 20:07:27 |
| 言語 | C++14 (gcc 13.3.0 + boost 1.87.0) |
| 結果 |
AC
|
| 実行時間 | 30 ms / 2,000 ms |
| コード長 | 359 bytes |
| コンパイル時間 | 1,570 ms |
| コンパイル使用メモリ | 159,792 KB |
| 実行使用メモリ | 25,984 KB |
| 平均クエリ数 | 30.11 |
| 最終ジャッジ日時 | 2025-01-26 00:05:59 |
| 合計ジャッジ時間 | 5,105 ms |
|
ジャッジサーバーID (参考情報) |
judge4 / judge2 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 44 |
ソースコード
#include <bits/stdc++.h>
using namespace std;
using ll = long long;
int main(){
int m = 30;
int h = 0,t = 1000000001;
for(int i=0;i<m;i++){
int c = (h+t) / 2 + 1;
cout << c << endl;
int che;
cin >> che;
if(che == 0) t = c-1;
else h = c;
if(t == h) break;
}
cout << h << endl;
}
Shizen