結果

問題 No.305 鍵(2)
ユーザー maine_honzukimaine_honzuki
提出日時 2021-05-14 19:24:07
言語 C++17
(gcc 13.2.0 + boost 1.83.0)
結果
AC  
実行時間 27 ms / 2,000 ms
コード長 569 bytes
コンパイル時間 1,827 ms
コンパイル使用メモリ 197,792 KB
実行使用メモリ 24,228 KB
平均クエリ数 86.69
最終ジャッジ日時 2023-09-24 02:58:43
合計ジャッジ時間 3,437 ms
ジャッジサーバーID
(参考情報)
judge14 / judge13
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 27 ms
24,096 KB
testcase_01 AC 23 ms
23,640 KB
testcase_02 AC 22 ms
24,108 KB
testcase_03 AC 22 ms
23,412 KB
testcase_04 AC 25 ms
24,228 KB
testcase_05 AC 22 ms
23,700 KB
testcase_06 AC 20 ms
23,604 KB
testcase_07 AC 24 ms
23,604 KB
testcase_08 AC 22 ms
23,388 KB
testcase_09 AC 21 ms
23,652 KB
testcase_10 AC 22 ms
24,060 KB
testcase_11 AC 21 ms
23,436 KB
testcase_12 AC 23 ms
23,448 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

//https://ncode.syosetu.com/n4830bu/305/
#include <bits/stdc++.h>
using namespace std;

int main() {
    string ans = "0000000000";
    int bef = 0;
    for (int i = 0; i < 10; i++) {
        for (int j = 0; j < 10; j++) {
            string maine = ans;
            maine[i] = j + '0';
            cout << maine << endl;
            int book;
            string s;
            cin >> book >> s;
            if (book == 10)
                return 0;
            if (book > bef) {
                bef = book;
                ans = maine;
            }
        }
    }
}
0