#!/bin/python3 import sys n = int(input().strip()) height = [int(height_temp) for height_temp in input().strip().split(' ')] sh = sorted(height,reverse=True) n_c = 1 i = 1 while i < n and sh[i] == sh[0]: n_c += 1 i += 1 print(n_c)