from collections import defaultdict

n = int(input())
aa = list(map(int, input().split()))


d = defaultdict(int)


def rating(num):
    if num <= 399:
        d[1] = 1
    elif 400 <= num <= 799:
        d[2] = 1
    elif 400 <= num <= 799:
        d[3] = 1
    elif 800 <= num <= 1199:
        d[4] = 1
    elif 1200 <= num <= 1599:
        d[5] = 1
    elif 1600 <= num <= 1999:
        d[6] = 1
    elif 2000 <= num <= 2399:
        d[7] = 1
    elif 2400 <= num <= 2799:
        d[8] = 1
    elif 2800 <= num <= 3199:
        d[9] = 1
    else:
        d[0] += 1


for a in aa:
    rating(a)

free = d[0]
cnt = len(d)-1


if free <= 0:
    print(cnt, cnt)
elif cnt == 0:
    print(1, cnt)
    exit()
else:
    print(cnt, min(8, cnt+free))
