結果

問題 No.1317 月曜日の朝、WAを出した
ユーザー firiexpfiriexp
提出日時 2021-01-22 18:49:08
言語 C++17
(gcc 12.3.0 + boost 1.83.0)
結果
AC  
実行時間 29 ms / 1,500 ms
コード長 983 bytes
コンパイル時間 941 ms
コンパイル使用メモリ 102,292 KB
実行使用メモリ 4,380 KB
最終ジャッジ日時 2023-08-27 14:37:31
合計ジャッジ時間 1,442 ms
ジャッジサーバーID
(参考情報)
judge12 / judge14
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 2 ms
4,376 KB
testcase_01 AC 29 ms
4,376 KB
testcase_02 AC 28 ms
4,380 KB
testcase_03 AC 29 ms
4,380 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

#include <iostream>
#include <algorithm>
#include <map>
#include <set>
#include <queue>
#include <stack>
#include <numeric>
#include <bitset>
#include <cmath>

static const int MOD = 1000000007;
using ll = long long;
using u32 = unsigned;
using u64 = unsigned long long;
using namespace std;

template<class T> constexpr T INF = ::numeric_limits<T>::max() / 32 * 15 + 208;

void solve(){
    vector<int> a(6), b(6);
    for (auto &&i : a) scanf("%d", &i);
    for (auto &&i : b) scanf("%d", &i);
    string s;
    cin >> s;
    int cur = 1;
    if(s == "TLE") cur = 2;
    if(s == "MLE") cur = 3;
    if(s == "OLE") cur = 4;
    if(s == "RE") cur = 5;
    for (int i = 1; i <= 5; ++i) {
        if(cur != i && b[i] != 0){
            puts("No");
            return;
        }
        if(cur == i && a[i] != 0){
            puts("No");
            return;
        }
    }
    puts("Yes");
}

int main() {
    int t;
    cin >> t;
    while(t--){
        solve();
    }
    return 0;
}
0