n = int(input())
a = list(map(int,input().split()))
ans = [0] * 9
for aa in a:
  if aa <= 399:
    ans[0] += 1
  elif 400 <= aa <= 799:
    ans[1] += 1
  elif 800 <= aa <= 1199:
    ans[2] += 1
  elif 1200 <= aa <= 1599:
    ans[3] += 1
  elif 1600 <= aa <= 1999:
    ans[4] += 1
  elif 2000 <= aa <= 2399:
    ans[5] += 1 
  elif 2400 <= aa <= 2799:
    ans[6] += 1
  elif 2800 <= aa <= 3199:
    ans[7] += 1
  elif aa >= 3200:
    ans[8] += 1

if ans[-1] == 0:
  n = 9-ans.count(0)
  print(n,n)
else:
  n = 9-ans.count(0)
  if ans[:-1].count(0) >= 2:
    print(n,n+2)
  elif ans[:-1].count(0) == 1:
    print(n,n+1)
  elif ans[:-1].count(0) == 0:
    print(n,n)