15 teams scored 665 points on this task, for a maximum score of 100, an average score of 44 and a median score of 25.
Edoardo heard some strange noises coming from his elevator, so he has been tracking which trips the elevator has made in order to find where the problem is. At the beginning, the elevator was at floor F_0. Then, the elevator made N-1 trips, reaching after the i-th trip the floor F_i (1 < i < N-1). Edoardo wants to know which is the most visited floor, that is the floor where the elevator passed the most number of times during all the trips. Please note that the floors where the elevator began or ended its trips are counted only once and not twice. Edoardo, however, is not really sure that he tracked the elevator correctly, so he has made Q consecutive changes to the trips. In particular, the j-th time he change the value of F_P_j to V_j. Can you tell Edoardo which is the most visited floor after each change and how many times it has been visited?