結果

問題 No.441 和か積
ユーザー ohreitetsu
提出日時 2018-05-29 15:54:46
言語 C++14
(gcc 13.3.0 + boost 1.87.0)
結果
WA  
実行時間 -
コード長 505 bytes
コンパイル時間 479 ms
コンパイル使用メモリ 64,092 KB
実行使用メモリ 6,944 KB
最終ジャッジ日時 2024-06-30 08:01:28
合計ジャッジ時間 1,403 ms
ジャッジサーバーID
(参考情報)
judge5 / judge2
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 3
other AC * 29 WA * 1
権限があれば一括ダウンロードができます

ソースコード

diff #

#include <iostream>
#include <string>
using namespace std;
int main(int argc, char* argv[])
{
	string A,B;
	cin>>A>>B;
	if (A[0]=='0' && B[0]=='0'){
		cout<<"E"<<endl;
		return 0;
	}
	if (A[0]=='0' || B[0]=='0'){
		cout<<"S"<<endl;
		return 0;
	}
	if (!A.compare("1") && !B.compare("1")){
		cout<<"E"<<endl;
		return 0;
	}
	if (!A.compare("1") || !B.compare("1")){
		cout<<"S"<<endl;
		return 0;
	}
	if (!A.compare("2") && !B.compare("2")){
		cout<<"E"<<endl;
		return 0;
	}
	cout<<"P"<<endl;
	return 0;
}
0