n=int(input())
a=list(map(int,input().split()))
red=0
kind=0
b=[]
for i in range(8):
    b.append([i,0])
for i in range(n):
    if a[i]<3200:
        b[a[i]//400][1]+=1
    else:
        red+=1
for i in range(8):
    if b[i][1]!=0:
        kind+=1
minc=1 if kind==0 else kind
maxc=kind+red if kind+red<=8 else 8
print(str(minc)+" "+str(maxc))