n = int(input())
A = list(map(int, input().split()))
L = [0]*8
for a in A:
    n = a//400
    if n > 7:
        L.append(1)
    else:
        L[n] = 1
m1, m2 = int(), int()
cnt = 0
for i in range(len(L)):
    l = L[i]
    if l == 1:
        if i > 7:
            m2 += 1
            if cnt == 0:
                m1 += 1
        else:
            cnt += 1
            m1 += 1
            m2 += 1

#print(L)
print(m1, m2)
