n = int(input())
a = list(map(int, input().split()))
color = [0]*8
for i in a:
  color[min(8,i//400)] += 1
kind = 0
for i in color[:7]:
  if i:
    kind += 1
if kind == 0 and color[7]:
  color[7] -= 1
  kind += 1
print(kind,kind+color[7])