시간 제한메모리 제한제출정답맞힌 사람정답 비율
1 초 128 MB63075123479482.927%

문제

대한고등학교에 재학 중인 민국이와 만세는 4과목(정보, 수학, 과학, 영어)에 대한 시험을 봤다. 민국이와 만세가 본 4과목의 점수를 입력하면, 민국이의 총점 S와 만세의 총점 T 중에서 큰 점수를 출력하는 프로그램을 작성하시오. 단, 서로 동점일 때는 민국이의 총점 S를 출력한다.

입력

입력은 2줄로 이루어져 있다.

1번째 줄에는 순서대로 민국이의 정보, 수학, 과학, 영어 점수(정수형)가 있으며, 공백으로 구분되어 있다.

2번째 줄에는 1번째 줄과 마찬가지로 순서대로 만세의 정보, 수학, 과학, 영어 점수(정수형)가 있고, 공백으로 구분되어 있다.

출력

문제에서 요구하는 정답을 출력한다.

예제 입력 1

100 80 70 60
80 70 80 90

예제 출력 1

320

예제 입력 2

100 80 70 60
80 70 60 100

예제 출력 2

310
W3sicHJvYmxlbV9pZCI6IjU1OTYiLCJwcm9ibGVtX2xhbmciOiIwIiwidGl0bGUiOiJcdWMyZGNcdWQ1ZDggXHVjODEwXHVjMjE4IiwiZGVzY3JpcHRpb24iOiI8cD5cdWIzMDBcdWQ1NWNcdWFjZTBcdWI0ZjFcdWQ1NTlcdWFkNTBcdWM1ZDAgXHVjN2FjXHVkNTU5IFx1YzkxMVx1Yzc3OCBcdWJiZmNcdWFkNmRcdWM3NzRcdWM2NDAgXHViOWNjXHVjMTM4XHViMjk0IDRcdWFjZmNcdWJhYTkoXHVjODE1XHViY2Y0LCBcdWMyMThcdWQ1NTksIFx1YWNmY1x1ZDU1OSwgXHVjNjAxXHVjNWI0KVx1YzVkMCBcdWIzMDBcdWQ1NWMgXHVjMmRjXHVkNWQ4XHVjNzQ0IFx1YmQyNFx1YjJlNC4gXHViYmZjXHVhZDZkXHVjNzc0XHVjNjQwIFx1YjljY1x1YzEzOFx1YWMwMCBcdWJjZjgmbmJzcDs0XHVhY2ZjXHViYWE5XHVjNzU4IFx1YzgxMFx1YzIxOFx1Yjk3Yy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