n = int(input())
a = map(int,input().split())
s = set()
g = 0
c = 0
for ai in a:
    x = ai//400
    if x<8:
        c+=1
        s.add(x)
    else:
        g+=1
if g>=7:
    g-=7
    ma=len(s)+g
else:
    ma=len(s)+g
if c>=1:
    mi=len(s)
else:
    mi=1
print(mi,ma)