A = [False] * 8 + [0]
n = int(input())
B = [int(i) for i in input().split()]

for i in B:
    if i < 400:
        A[0] = True
    elif i < 800:
        A[1] = True
    elif i < 1200:
        A[2] = True
    elif i < 1600:
        A[3] = True
    elif i < 2000:
        A[4] = True
    elif i < 2400:
        A[5] = True
    elif i < 2800:
        A[6] = True
    elif i < 3200:
        A[7] = True
    else:
        A[8] += 1
        
ured = sum(A[0:8])
minc = (1 if ured == 0 else ured)
maxc = min(8, ured + A[8])
print(minc, maxc)