結果

問題 No.975 ミスターマックスバリュ
ユーザー yuma220284yuma220284
提出日時 2020-03-08 14:31:47
言語 C++11
(gcc 11.4.0)
結果
WA  
実行時間 -
コード長 506 bytes
コンパイル時間 1,527 ms
コンパイル使用メモリ 157,784 KB
実行使用メモリ 5,376 KB
最終ジャッジ日時 2024-04-24 19:31:16
合計ジャッジ時間 2,318 ms
ジャッジサーバーID
(参考情報)
judge5 / judge3
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 2 ms
5,248 KB
testcase_01 AC 1 ms
5,376 KB
testcase_02 WA -
testcase_03 WA -
testcase_04 AC 2 ms
5,376 KB
testcase_05 AC 2 ms
5,376 KB
testcase_06 AC 1 ms
5,376 KB
testcase_07 AC 2 ms
5,376 KB
testcase_08 AC 6 ms
5,376 KB
testcase_09 WA -
testcase_10 WA -
権限があれば一括ダウンロードができます

ソースコード

diff #

#include "bits/stdc++.h"
using namespace std;

int main() {
	long long X, N, M, A, B;
	bool checkA = false, checkB = false;
	cin >> X >> N >> M;
	for (int i = 0; i < N; i++) {
		cin >> A;
		if (X == A) checkA = true;
	}
	for (int i = 0; i < N; i++) {
		cin >> B;
		if (X == B) checkB = true;
	}
	if (checkA) {
		if (checkB) {
			cout << "MrMaxValue" << endl;
		}
		else {
			cout << "MrMax" << endl;
		}
	}
	else {
		if (checkB) {
			cout << "MaxValue" << endl;
		}
		else {
			cout << -1 << endl;
		}
	}
}
0