100 atcoder#ABC110B. [ABC110B] 1 Dimensional World's Tale
[ABC110B] 1 Dimensional World's Tale
Score : points
Problem Statement
Our world is one-dimensional, and ruled by two empires called Empire A and Empire B.
The capital of Empire A is located at coordinate , and that of Empire B is located at coordinate .
One day, Empire A becomes inclined to put the cities at coordinates under its control, and Empire B becomes inclined to put the cities at coordinates under its control.
If there exists an integer that satisfies all of the following three conditions, they will come to an agreement, but otherwise war will break out.
Determine if war will break out.
Constraints
- All values in input are integers.
- are all different.
- are all different.
Input
Input is given from Standard Input in the following format:
Output
If war will break out, print War
; otherwise, print No War
.
3 2 10 20
8 15 13
16 22
No War
The choice satisfies all of the three conditions as follows, thus they will come to an agreement.
4 2 -48 -1
-20 -35 -91 -23
-22 66
War
5 3 6 8
-10 3 1 5 -100
100 6 14
War