N = int(input())
nums=[int(i) for i in input().split()]
colors = []
noncolor = 0
for num in nums:
	if 1<=num and num<=399:
		colors.append(1)
	elif 400<=num and num<=799:
		colors.append(2)
	elif 800<=num and num<=1199:
		colors.append(3)
	elif 1200<=num and num<=1599:
		colors.append(4)
	elif 1600<=num and num<=1999:
		colors.append(5)
	elif 2000<=num and num<=2399:
		colors.append(6)
	elif 2400<=num and num<=2799:
		colors.append(7)
	elif 2800<=num and num<=3199:
		colors.append(8)
	else:
		noncolor+=1
colors = set(colors)
maxnum = 0
minnim = 0
if (len(colors)+noncolor)>=8:
    maxnum = 8
if (len(colors)+noncolor)<8:
    maxnum = len(colors)+noncolor
if len(colors)>=1:
    minnim = len(colors)
if len(colors)==0:
    minnim = 1
print("{} {}".format(minnim,maxnum))