n = int(input())
a = list(map(int, input().split()))
l = [0] * 9
for i in a:
    if i >= 3200:
        l[8] += 1
    else:
        l[i // 400] += 1
mi = 0
ma = 0
for i in l[:8]:
    if i > 0:
        mi += 1
        ma += 1
if l[8] > 0:
    ma += l[8]
print(mi, ma)