Loading [MathJax]/jax/output/CommonHTML/jax.js

Problem A. Axis of choice

Author:A. Klenin   Time limit:1 sec
Input file:input.txt   Memory limit:256 Mb
Output file:output.txt  

Statement

A rectangular area with sides parallel to coordinate axises is represented by coordinates of two opposite corners (x1,y1) and (x2,y2).

Your program must find the coordinate axis which is closest to the given rectangular area.

Input file format

Input file contains four integers x1y1x2y2 — coordinates of area corners.

Output file format

Output file must contain a single string:

Constraints

109x1,y1,x2,y2109

Sample tests

No. Input file (input.txt) Output file (output.txt)
1
30 40 10 20
Y
2
-5 20 -4 -20
X
3
1 1 1 1
XY

0.065s 0.011s 13