N = input()
L = [1,2,3,4,5,6,7,8]
M = 0
for x in input().split():
    x = int(x)
    if 400 > x:
        v = 1
    elif 800 > x:
        v = 2
    elif 1200 > x:
        v = 3
    elif 1600 > x:
        v = 4
    elif 2000 > x:
        v = 5
    elif 2400 > x:
        v = 6
    elif 2800 > x:
        v = 7
    elif 3200 > x:
        v = 8
    else:
        M += 1
        continue
    if v in L:
        L.remove(v)
C = 8 - len(L)
print(str(C)+" "+str(C + M))
