N=int(input())
a=[0,]*9
rates=list(map(int,input().split()))
for i in range(N):
    rank=int(rates[i]/400)
    if rank>8:
        rank=8
    a[rank]+=1
variation=0
for i in range(8):
    if a[i] > 0:
        variation+=1
print(str(variation)+" "+str(variation+a[8]))