n=int(input())
l=list(map(int,input().split()))
c=[0]*8;free=0
for x in l:
  if x<400:
    c[0]+=1
  elif x<800:
    c[1]+=1
  elif x<1200:
    c[2]+=1
  elif x<1600:
    c[3]+=1
  elif x<2000:
    c[4]+=1
  elif x<2400:
    c[5]+=1
  elif x<2800:
    c[6]+=1
  elif x<3200:
    c[7]+=1
  else: free+=1
cnt=0
for x in c:
  if x>0:cnt+=1
print(cnt,cnt+free)