結果

問題 No.1317 月曜日の朝、WAを出した
ユーザー 沙耶花沙耶花
提出日時 2020-12-14 02:11:24
言語 C++17
(gcc 12.3.0 + boost 1.83.0)
結果
AC  
実行時間 40 ms / 1,500 ms
コード長 645 bytes
コンパイル時間 2,758 ms
コンパイル使用メモリ 214,456 KB
実行使用メモリ 4,348 KB
最終ジャッジ日時 2023-10-20 04:37:31
合計ジャッジ時間 3,188 ms
ジャッジサーバーID
(参考情報)
judge14 / judge13
このコードへのチャレンジ
(要ログイン)

テストケース

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

ソースコード

diff #

#include <stdio.h>
#include <bits/stdc++.h>
using namespace std;
#define rep(i,n) for (int i = 0; i < (n); ++i)
#define Inf 1000000000

int main(){
	
	int N;
	cin>>N;
	
	map<string,int> mp;
	mp["WA"] = 1;
	mp["TLE"] = 2;
	mp["MLE"] = 3;
	mp["OLE"] = 4;
	mp["RE"] = 5;
	
	rep(_,N){
		vector<int> x(6),y(6);
		rep(i,6)cin>>x[i];
		rep(i,6)cin>>y[i];
		string s;
		cin>>s;
		
		int ind = mp[s];
		if(x[ind]!=0){
			cout<<"No"<<endl;
			continue;
		}
		bool f  =true;
		rep(i,6){
			if(i==0)continue;
			if(i==ind)continue;
			if(y[i]!=0){
				cout<<"No"<<endl;
				f=false;
				break;
			}
		}
		
		if(f)cout<<"Yes"<<endl;
	}
			
	
    return 0;
}
0