n = gets.to_i 
a = gets.split.map(&:to_i)
colors = Array.new(8, 0)
ra = 0
total = 0
#puts n
#puts a
n.times do |i|
  if a[i] >= 3200
    ra += 1
  else
    colors[ a[i] / 400 ] = 1
  end
end
8.times do |i|
	total = total + colors[i]
end
cmax = total + ra
if cmax > 8
	cmax = 8
end
if total < 1
	total = 1
end
puts puts "#{total} #{cmax}"
#puts total
#puts cmax