N=int(input())
a=list(map(int,input().split()))
count_color=[0]*8
wild_color=0
for i in range (N):
    if a[i]<400:
        count_color[0]=1
    elif a[i]<800:
        count_color[1]=1
    elif a[i]<1200:
        count_color[2]=1
    elif a[i]<1600:
        count_color[3]=1
    elif a[i]<2000:
        count_color[4]=1
    elif a[i]<2400:
        count_color[5]=1
    elif a[i]<2800:
        count_color[6]=1
    elif a[i]<3200:
        count_color[7]=1
    else:
        wild_color+=1
color=count_color.count(1)
print (color, min(color+wild_color,9))