結果
| 問題 | No.305 鍵(2) |
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2019-08-12 17:46:27 |
| 言語 | C++17 (gcc 15.2.0 + boost 1.89.0) |
| 結果 |
AC
|
| 実行時間 | 28 ms / 2,000 ms |
| コード長 | 499 bytes |
| 記録 | |
| コンパイル時間 | 1,144 ms |
| コンパイル使用メモリ | 209,816 KB |
| 実行使用メモリ | 29,936 KB |
| 平均クエリ数 | 52.15 |
| 最終ジャッジ日時 | 2026-06-07 16:42:03 |
| 合計ジャッジ時間 | 2,686 ms |
|
ジャッジサーバーID (参考情報) |
judge3_0 / judge1_0 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 13 |
ソースコード
#include <bits/stdc++.h>
using namespace std;
typedef long long ll;
int main() {
string s="0000000000";
cout<<s<<endl;
int a;string t;
cin>>a>>t;
if (a==10) return 0;
int i=0;
s[i]++;
while (true) {
cout<<s<<endl;
int b;
cin>>b>>t;
if (b==10) break;
if (b>a) {
a=b;
i++;
} else if (b<a) {
s[i]--;
i++;
} else {
s[i]++;
}
}
return 0;
}