N = int(input())
lst_a = list(map(int, input().split()))
lst_color = [0] * 9


for a in lst_a:
    if 1 <= a <= 399:
        lst_color[0] += 1
    elif 400 <= a <= 799:
        lst_color[1] += 1
    elif 800 <= a <= 1199:
        lst_color[2] += 1
    elif 1200 <= a <= 1599:
        lst_color[3] += 1
    elif 1600 <= a <= 1999:
        lst_color[4] += 1
    elif 2000 <= a <= 2399:
        lst_color[5] += 1
    elif 2400 <= a <= 2799:
        lst_color[6] += 1
    elif 2800 <= a <= 3199:
        lst_color[7] += 1
    else:
        lst_color[8] += 1
num_existed_rate = sum(1 for x in lst_color[:8] if x!=0)


num_super = lst_color[8]
num_uncolored = 8 - num_existed_rate
if num_super >= num_uncolored:
    num_max = 8
else:
    num_max = num_existed_rate + num_super
if num_existed_rate == 0:
    num_min = 1
else:
    num_min = num_existed_rate


print(num_min, num_max)