結果

問題 No.331 CodeRunnerでやれ
ユーザー parukiparuki
提出日時 2018-03-11 19:13:06
言語 C++14
(gcc 12.3.0 + boost 1.83.0)
結果
AC  
実行時間 4,184 ms / 5,000 ms
コード長 1,024 bytes
コンパイル時間 1,651 ms
コンパイル使用メモリ 165,600 KB
実行使用メモリ 24,316 KB
平均クエリ数 16738.00
最終ジャッジ日時 2023-09-24 01:40:34
合計ジャッジ時間 20,324 ms
ジャッジサーバーID
(参考情報)
judge12 / judge14
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 137 ms
23,676 KB
testcase_01 AC 128 ms
24,264 KB
testcase_02 AC 358 ms
23,356 KB
testcase_03 AC 203 ms
24,016 KB
testcase_04 AC 244 ms
23,964 KB
testcase_05 AC 243 ms
24,192 KB
testcase_06 AC 209 ms
24,012 KB
testcase_07 AC 562 ms
23,796 KB
testcase_08 AC 373 ms
24,172 KB
testcase_09 AC 1,127 ms
23,368 KB
testcase_10 AC 315 ms
23,404 KB
testcase_11 AC 4,184 ms
23,668 KB
testcase_12 AC 509 ms
23,620 KB
testcase_13 AC 483 ms
24,024 KB
testcase_14 AC 2,364 ms
23,520 KB
testcase_15 AC 1,137 ms
23,524 KB
testcase_16 AC 3,323 ms
24,316 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

#include "bits/stdc++.h"
using namespace std;
#define FOR(i,j,k) for(int (i)=(j);(i)<(int)(k);++(i))
#define rep(i,j) FOR(i,0,j)
#define each(x,y) for(auto &(x):(y))
#define mp make_pair
#define all(x) (x).begin(),(x).end()
#define debug(x) cout<<#x<<": "<<(x)<<endl
#define smax(x,y) (x)=max((x),(y))
#define smin(x,y) (x)=min((x),(y))
#define MEM(x,y) memset((x),(y),sizeof (x))
#define sz(x) (int)(x).size()
typedef long long ll;
typedef pair<int, int> pii;
typedef vector<int> vi;
typedef vector<ll> vll;

const int INF = 20151224;

int order(char c){
    cout << c << endl;
    string res;
    cin >> res;
    if(res[0]=='M')
        exit(0);
    return stoi(res);
}

int rnd(int mod){
    return rand() % mod;
}

int main(){
    {string s; cin >> s; }
    while(1){
        int cnt = rnd(4);
        int res = 0;
        rep(i, cnt)
            res = order('L');
        if(res == 0)continue;
        if(res == INF)
            while(1)order('F');
        int len = rnd(res) + 1;
        rep(i, len)order('F');
    }
}
0