import sequtils, strutils, math, algorithm

var
  n = parseInt(readLine(stdin))
  a = readLine(stdin).split().map(parseInt)
  count = newseqWith(9, 0)
for an in a:
  if an < 3200:
    inc(count[an div 400])
  else:
    inc(count[8])
var
  count_red = filter(count[0..7], proc(x:int): bool = x > 0).len
  count_zero = filter(count[0..7], proc(x:int): bool = x == 0).len
if count_red == 0:
  echo 1, " ", count[8]
else:
  echo count_red + count[8] - min(count_red, count[8]), " ", count_red + count[8]