import sys
N = int(input())
r = list(map(int, input().split()))
if min(r) >= 3200:
  print(str(1)+' '+str(N))
  sys.exit()
li = [0 for i in range(9)]
for rates in r:
  n = rates//400
  li[n] += 1
p = 0
for nums in li[0:8]:
  if nums !=0:
    p += 1
print(str(p)+' '+str(p+li[8]))