n=int(input())
a=[int(i) for i in input().split()]
color=[0]*8
over=0
for i in range(n):
    if a[i]<=399:
        color[0]+=1
    elif a[i]<=799:
        color[1]+=1
    elif a[i]<=1199:
        color[2]+=1
    elif a[i]<=1599:
        color[3]+=1
    elif a[i]<=1999:
        color[4]+=1
    elif a[i]<=2399:
        color[5]+=1
    elif a[i]<=2799:
        color[6]+=1
    elif a[i]<=3199:
        color[7]+=1
    else:
        over+=1
mini=8-color.count(0) if (8-color.count(0))>0 else 1
maxi=8-color.count(0)+over if (8-color.count(0)+over)<8 else 8
print("{} {}".format(mini,maxi))