col = [0, 399, 799, 1199, 1599, 1999, 2399, 2799, 3199]
flag = [False for _ in range(len(col))]
n = int(input())
a = list(map(int, input().split()))
cnt = 0
for i in range(n):
    for j in range(1, len(col)):
        if col[j-1] < a[i] <= col[j]:
            flag[j] = True
        if a[i] >= 3200:
            cnt += 1
            break
bs = flag.count(True)
mn = bs
mx = min(bs+cnt, 8)
print(mn, mx)