n = int(input())
a = list(map(int, input().split()))
li = [0, 0, 0, 0, 0, 0, 0, 0, 0]
for i in range(n):
    if 1 <= a[i] <= 399:
        li[0] += 1
    elif 400 <= a[i] <= 799:
        li[1] += 1
    elif 800 <= a[i] <= 1199:
        li[2] += 1
    elif 1200 <= a[i] <= 1599:
        li[3] += 1
    elif 1600 <= a[i] <= 1999:
        li[4] += 1
    elif 2000 <= a[i] <= 2399:
        li[5] += 1
    elif 2400 <= a[i] <= 2799:
        li[6] += 1
    elif 2800 <= a[i] <= 3199:
        li[7] += 1
    else:
        li[8] += 1
if li[8] == 0:
    print(str(9 - li.count(0))+" "+str(9 - li.count(0)))
else:
    print(str(8 - li.count(0))+" "+str(8 - li.count(0)+li[8]))