N = int(input())
a = list(map(int, input().split()))

c = []
xn = 0
TF = [False for _ in range(8)]
for r in a:
    if r <= 399:
        c.append(0)
        TF[0] = True
    elif 400 <= r <= 799:
        c.append(1)
        TF[1] = True
    elif 800 <= r <= 1199:
        c.append(2)
        TF[2] = True
    elif 1200 <= r <= 1599:
        c.append(3)
        TF[3] = True
    elif 1600 <= r <= 1999:
        c.append(4)
        TF[4] = True
    elif 2000 <= r <= 2399:
        c.append(5)
        TF[5] = True
    elif 2400 <= r <= 2799:
        c.append(6)
        TF[6] = True
    elif 2800 <= r <= 3199:
        c.append(7)
        TF[7] = True
    else:
        c.append(100)
        xn += 1
truenum = sum(1 for i in TF if i)
minv = truenum
maxv = truenum + xn
if maxv > 8:
    maxv = 8
print(minv, maxv)