n = int(input())
A = list(map(int,input().split()))

rank = [0 for i in range(9)]

for a in A:
	res = min(a//400,8)
	rank[res] += 1

ans = 0
for r in rank[:-1]:
	if r == 0:
		continue
	ans+=1

min_ans = 0
max_ans = 0
if rank[-1] == 0:
	min_ans,max_ans = min(ans,8),min(ans,8)
else:
	if ans == 0:
		min_ans = 1
		max_ans = min(rank[-1],8)
	else:
		min_ans = min(ans,8)
		max_ans = min(ans+rank[-1],8)
print(min_ans,max_ans)