結果
| 問題 |
No.1317 月曜日の朝、WAを出した
|
| コンテスト | |
| ユーザー |
tnakao0123
|
| 提出日時 | 2020-12-18 23:16:51 |
| 言語 | C++14 (gcc 13.3.0 + boost 1.87.0) |
| 結果 |
WA
|
| 実行時間 | - |
| コード長 | 1,173 bytes |
| コンパイル時間 | 889 ms |
| コンパイル使用メモリ | 93,556 KB |
| 実行使用メモリ | 5,376 KB |
| 最終ジャッジ日時 | 2024-09-21 09:30:15 |
| 合計ジャッジ時間 | 1,370 ms |
|
ジャッジサーバーID (参考情報) |
judge2 / judge4 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 1 WA * 3 |
ソースコード
/* -*- coding: utf-8 -*-
*
* 1317.cc: No.1317 月曜日の朝、WAを出した - yukicoder
*/
#include<cstdio>
#include<cstdlib>
#include<cstring>
#include<cmath>
#include<iostream>
#include<string>
#include<vector>
#include<map>
#include<set>
#include<stack>
#include<list>
#include<queue>
#include<deque>
#include<algorithm>
#include<numeric>
#include<utility>
#include<complex>
#include<functional>
using namespace std;
/* constant */
const int M = 6;
const char ss[M][8] = { "AC", "WA", "TLE", "MLE", "OLE", "RE" };
enum { AC, WA, TLE, MLE, OLE, RE };
/* typedef */
/* global variables */
int cs[2][M];
/* subroutines */
/* main */
int main() {
int n;
scanf("%d", &n);
while (n--) {
for (int i = 0; i < 2; i++)
for (int j = 0; j < M; j++) scanf("%d", cs[i] + j);
char s[8];
scanf("%s", s);
int x = 0;
for (; strcmp(s, ss[x]) != 0; x++);
//puts(ss[x]);
int wsum = 0;
for (int j = 1; j < M; j++) wsum += cs[0][j];
bool ok = true;
for (int j = 1; ok && j < M; j++)
ok = (j == x && cs[1][j] >= wsum) || (j != x && cs[1][j] == 0);
if (ok) puts("Yes");
else puts("No");
}
return 0;
}
tnakao0123