MWC '15 #3 P1: Challenger Promos
View as PDFOver the course of  days, 
 players gain or lose 
 points on their base score 
. At the end of the 
 days, the top 
 players make it to the highest division which is called Challenger. Given players, their base scores, and their score change over 
 days, output the player with the 
 highest ranking (the last person to make it to Challenger).
Input Specification
The first line of input will contain one integer  
, the numbers of players.
The next  lines of input will contain a string up to 30 characters long which is the name of each player and their base score 
 
.
The next line of input will contain a single integer  
, the number of days.
The next  lines contain the name of each player and the net change of each player's score 
 
 on the 
 day.
The final line will contain one integer , the number of players that will make it to Challenger.
Output Specification
Output a string, the name of the last player to make it to Challenger.
Sample Input
7
Hypnova 1000
Twisch 1304
Meruvale 1234
Ferina 976
Destryn 958
Intoxify 1062
Flaere 999
2
Hypnova -3
Twisch 2
Meruvale -3
Ferina 4
Destryn -1
Intoxify 3
Flaere 26
Hypnova 1003
Twisch -2
Meruvale 112
Ferina -13
Destryn 12
Intoxify -44
Flaere 34
3
Sample Output
Twisch
Comments