n=int(input())
a=[int(i) for i in input().split()]
rate=[0,0,0,0,0,0,0,0,0]
for i in a:
    if i<400:
        rate[0]=1
    elif 400<=i<800:
        rate[1]=1
    elif 800<=i<1200:
        rate[2]=1
    elif 1200<=i<1600:
        rate[3]
    elif 1600<=i<2000:
        rate[4]=1
    elif 2000<=i<2400:
        rate[5]=1
    elif 2400<=i<2800:
        rate[6]=1
    elif 2800<=i<3200:
        rate[7]=1
    else:
        rate[8]+=1
color=rate[:8]
x=color.count(1)
color_max=x+rate[8]
if x==0 and rate[8]>0:
    color_min=1
else:
    color_min=x
print('{} {}'.format(color_min,color_max))