n = int(input())
a = list(map(int,input().split()))
col = [0]*8
over_cnt = 0
cnt_min = 0
for i in range(n):
	if a[i] < 3200:
		col[(a[i])//400] += 1
	else:
		over_cnt += 1
for j in col:
	if j > 0:
		cnt_min += 1
cnt_max = min(8,(cnt_min+ over_cnt))
print(cnt_min,cnt_max)