N = int(input())
a = [int(c) for c in input().split()]
c = [0]*9
for i in range(N):
    if a[i]>3200:
        c[8]+=1
    else:
        c[a[i]//400]+=1

mi = 8-c[0:8].count(0)
if mi+c[8]>8:
    ma = 8
else:
    ma = mi+c[8]
print(mi,ma)