package com.javarush.task.task04.task0419;
import java.io.BufferedReader;
import java.io.InputStreamReader;
import java.io.IOException;
/*
Максимум четырех чисел
*/
public class Solution {
public static void main(String[] args) throws Exception {
BufferedReader reader = new BufferedReader(new InputStreamReader(System.in));
String n1 = reader.readLine();
String n2 = reader.readLine();
String n3 = reader.readLine();
String n4 = reader.readLine();
int a = Integer.parseInt(n1);
int b = Integer.parseInt(n2);
int c = Integer.parseInt(n1);
int d = Integer.parseInt(n2);
int maxAB;
if(a >= b){
maxAB = a;
} else maxAB = b;
int maxCD;
if(c >= d){
maxCD = c;
} else maxCD = d;
if(maxAB >= maxCD){
System.out.println(maxAB);
} else System.out.println(maxCD);
}
}
package com.javarush.task.task04.task0419;
import java.io.BufferedReader;
import java.io.InputStreamReader;
import java.io.IOException;
/*
Максимум четырех чисел
*/
public class Solution {
public static void main(String[] args) throws Exception {
BufferedReader reader = new BufferedReader(new InputStreamReader(System.in));
String n1 = reader.readLine();
String n2 = reader.readLine();
String n3 = reader.readLine();
String n4 = reader.readLine();
int a = Integer.parseInt(n1);
int b = Integer.parseInt(n2);
int c = Integer.parseInt(n1);
int d = Integer.parseInt(n2);
int maxAB;
if(a >= b){
maxAB = a;
} else maxAB = b;
int maxCD;
if(c >= d){
maxCD = c;
} else maxCD = d;
if(maxAB >= maxCD){
System.out.println(maxAB);
} else System.out.println(maxCD);
}
}