N = int(input())
A = list(map(int,input().split()))

hai = 0
tya = 0
mizu = 0
ao = 0
ki = 0
dai = 0
aka = 0
mu = 0

for a in A:
  if a <= 399:
    hai = 1
  elif a <= 799:
    tya = 1
  elif a <= 1199:
    mizu = 1
  elif a <= 1599:
    ao = 1
  elif a <= 1999:
    ki = 1
  elif a <= 2399:
    dai = 1
  elif a <= 3199:
    aka = 1
  else:
    mu += 1
    
max_num = min(8, hai + tya + mizu + ao + ki + dai + aka + mu)
min_num = max(1, hai + tya + mizu + ao + ki + dai + aka)

print(min_num, max_num)