n = int(input())
l = list(map(int, input().split()))
d = {}
for i in range(n):
  if 1<=l[i]<=399:
    a = 0
  elif 400<=l[i]<=799:
    a = 1
  elif 800<=l[i]<=1199:
    a = 2
  elif 1200<=l[i]<=1599:
    a = 3
  elif 1600<=l[i]<=1999:
    a = 4
  elif 2000<=l[i]<=2399:
    a = 5
  elif 2400<=l[i]<=2799:
    a = 6
  elif 2800<=l[i]<=3199:
    a = 7
  else:
    a = 8
  if a in d:
    d[a] += 1
  else:
    d[a] = 1
if not(8 in d):
  d[8] = 0
#print(d)
print(len(d.keys())-1, len(d.keys())-1+d[8])

  