#coding: utf-8
N = int(raw_input())
rates = map(int, raw_input().split(' '))

color_num = {}
for r in rates:
	mod = r / 400
	if mod > 7:
		mod = 8
	color_num[mod] = color_num.setdefault(mod, 0) + 1

minnum = len(color_num)
maxnum = minnum
if 8 in color_num:
	minnum -= 1
	maxnum += color_num[8] - 1
	
print '{} {}'.format(minnum, maxnum)