Submission #3251894


Source Code Expand

Copy
#include <iostream>
#include <string>
#include <vector>
#include <utility>
#include <set>
#include <map>
#include <unordered_map>

using namespace std;
const int maxn = 102;

int n, m, X, Y, x, y;

int main()
{
	cin >> n >> m >> X >> Y;

	int maxx = -101;

	for (int i = 1; i <= n; ++i) {
		cin >> x;
		if (x > maxx)
			maxx = x;
	}

	if (maxx >= Y) {
		cout << "War" << endl;
		return 0;
	}

	int miny = 101;
	for (int i = 1; i <= m; ++i) {
		cin >> y;
		if (y < miny)
			miny = y;
	}

	if (miny <= X || maxx >= miny)
		cout << "War" << endl;
	else 
		cout << "No War" << endl;
	

	return 0;
}

Submission Info

Submission Time
Task B - 1 Dimensional World's Tale
User suzyz
Language C++14 (GCC 5.4.1)
Score 200
Code Size 638 Byte
Status AC
Exec Time 1 ms
Memory 256 KB

Judge Result

Set Name All Sample
Score / Max Score 200 / 200 0 / 0
Status
AC × 17
AC × 3
Set Name Test Cases
All hand1, hand2, max1, max2, max3, max4, max5, max7, max8, normal1, normal2, normal3, normal4, normal5, sample_01, sample_02, sample_03
Sample sample_01, sample_02, sample_03
Case Name Status Exec Time Memory
hand1 AC 1 ms 256 KB
hand2 AC 1 ms 256 KB
max1 AC 1 ms 256 KB
max2 AC 1 ms 256 KB
max3 AC 1 ms 256 KB
max4 AC 1 ms 256 KB
max5 AC 1 ms 256 KB
max7 AC 1 ms 256 KB
max8 AC 1 ms 256 KB
normal1 AC 1 ms 256 KB
normal2 AC 1 ms 256 KB
normal3 AC 1 ms 256 KB
normal4 AC 1 ms 256 KB
normal5 AC 1 ms 256 KB
sample_01 AC 1 ms 256 KB
sample_02 AC 1 ms 256 KB
sample_03 AC 1 ms 256 KB