n = int(input())
rt = list(map(int,input().split()))
clr = [0 for _ in range(9)]
for i in range(n):
  now = rt[i]
  for j in range(8):
    if now < 400 * (j+1):
      clr[j] += 1
      break
  else:
    clr[8] += 1
ans = 0
top = clr[8]
for j in range(8):
  if clr[j] != 0:
    ans += 1
if top == 0:
  print(str(ans) + ' ' + str(ans))
else:
  print(str(max(ans,1)) + ' ' + str(min(8,ans+top)))
#print(clr)