RobloxOA #10
Largest Value of Usage in Minutes
估计简单可在线判题
考点(AI 标注)字符串
Each record contains a five-letter lowercase device_id and a four-digit usage (leading zeros allowed); return the device ID with the largest usage. Device IDs are pairwise distinct, and so are the usage values.
输入格式
The first line contains n; each of the next n lines is device_id usage. This site's input protocol omits the comma and space of the original format to resolve the contradiction between its length=10 and the length of the example strings. 1≤n≤1400; each ID is exactly 5 lowercase English letters; usage is interpreted as an integer with 1≤usage≤1400 (the intersection of the original prose and constraints).
输出格式
Output the device_id with the largest usage.
样例 1
输入:
3
iqttt 0077
obvhd 0093
flohd 0075
输出:
obvhd
样例 2
输入:
1
abcde 0001
输出:
abcde
样例 3
输入:
2
zzzzz 1400
aaaaa 1399
输出:
zzzzz