#abc215f. [abc215_f]Dist Max 2
[abc215_f]Dist Max 2
Problem Statement
Given are distinct points in a two-dimensional plane. Point has the coordinates .
Let us define the distance between two points and be : the smaller of the difference in the -coordinates and the difference in the -coordinates.
Find the maximum distance between two different points.
Constraints
- All values in input are integers.
Input
Input is given from Standard Input in the following format:
Output
Print the maximum distance between two different points.
Sample Input 1
3
0 3
3 1
4 10
Sample Output 1
4
The distances between Points and , between Points and , and between Points and are , , and , respectively, so your output should be .
Sample Input 2
4
0 1
0 4
0 10
0 6
Sample Output 2
0
Sample Input 3
8
897 729
802 969
765 184
992 887
1 104
521 641
220 909
380 378
Sample Output 3
801