n = int(input())
a = list(map(int, input().split()))
a.sort()
b = [0] * 8
cntmax = 0
cnt = 0
for i in a:
    if i >= 3200:
        cntmax += 1
    else:
        b[i // 400] += 1

for i in b:
    if i != 0:
        cnt += 1
# print(b)
if cnt == 0:
    print(1, cntmax if cntmax <= 8 else 8)
    exit()

s = cnt + cntmax
if s > 8:
    s = 8

print(cnt, s)
