n = int(input())
a = map(int, input().split())

colors = [False] * 8
crown_owners = 0

for rate in a:
	if rate <= 399:
		colors[0] = True
	elif rate <= 799:
		colors[1] = True
	elif rate <= 1199:
		colors[2] = True
	elif rate <= 1599:
		colors[3] = True
	elif rate <= 1999:
		colors[4] = True
	elif rate <= 2399:
		colors[5] = True
	elif rate <= 2799:
		colors[6] = True
	elif rate <= 3199:
		colors[7] = True
	else:
		crown_owners += 1

print(colors.count(True), colors.count(True) + crown_owners)