Find the Runner-Up Score!

  • + 1 comment
    if __name__ == '__main__':
        n = int(input())
        arr = map(int, input().split())
        
    arr = set(arr)
    max_score = max(arr)
    runner_up_score = -101
    
    for score in arr:
        if score != max_score:
            runner_up_score = max(runner_up_score, score)
            
    print(runner_up_score)