QOJ.ac

QOJ

実行時間制限: 2 s メモリ制限: 64 MB 満点: 100

#23756. คะแนน

統計

นักเรียน $2$ คนของโรงเรียนมัธยม JOI คือคุณ A และคุณ B ได้เข้าสอบใน $4$ วิชา ได้แก่ สารสนเทศ คณิตศาสตร์ วิทยาศาสตร์ และภาษาอังกฤษ เมื่อกำหนดคะแนนทั้ง $4$ วิชานี้ของคุณ A และคุณ B จงเขียนโปรแกรมเพื่อแสดงค่าที่มากกว่าระหว่างคะแนนรวม $S$ ของคุณ A กับคะแนนรวม $T$ ของคุณ B อย่างไรก็ตาม หากคะแนนเท่ากัน ให้แสดงค่า $S$ ($= T$)

ข้อมูลนำเข้า

ข้อมูลนำเข้าประกอบด้วย $2$ บรรทัด

บรรทัดที่ $1$ มีจำนวนเต็ม $4$ จำนวนคั่นด้วยช่องว่าง $1$ ช่อง แทนคะแนนวิชาสารสนเทศ คะแนนวิชาคณิตศาสตร์ คะแนนวิชาวิทยาศาสตร์ และคะแนนวิชาภาษาอังกฤษของคุณ A ตามลำดับ

บรรทัดที่ $2$ มีจำนวนเต็ม $4$ จำนวนคั่นด้วยช่องว่าง $1$ ช่อง แทนคะแนนวิชาสารสนเทศ คะแนนวิชาคณิตศาสตร์ คะแนนวิชาวิทยาศาสตร์ และคะแนนวิชาภาษาอังกฤษของคุณ B ตามลำดับ

คะแนนของทุกวิชามีคะแนนเต็ม $100$ คะแนน และไม่มีการให้คะแนนติดลบ

ข้อมูลส่งออก

ข้อมูลส่งออกประกอบด้วยจำนวนเต็ม $1$ จำนวนที่ต้องการหา

ตัวอย่าง

ข้อมูลนำเข้า 1

100 80 70 60
80 70 80 90

ข้อมูลส่งออก 1

320

ข้อมูลนำเข้า 2

100 80 70 60
80 70 60 100

ข้อมูลส่งออก 2

310

Discussions

About Discussions

The discussion section is only for posting: General Discussions (problem-solving strategies, alternative approaches), and Off-topic conversations.

This is NOT for reporting issues! If you want to report bugs or errors, please use the Issues section below.

Open Discussions 0
No discussions in this category.

Issues

About Issues

If you find any issues with the problem (statement, scoring, time/memory limits, test cases, etc.), you may submit an issue here. A problem moderator will review your issue.

Guidelines:

  1. This is not a place to publish discussions, editorials, or requests to debug your code. Issues are only visible to you and problem moderators.
  2. Do not submit duplicated issues.
  3. Issues must be filed in English or Chinese only.
Active Issues 0
No issues in this category.
Closed/Resolved Issues 0
No issues in this category.