N = int(input())
*a, = map(int, input().split())
var = 0
cnt = [0] * 8

for i in a:
	if i < 400:
		cnt[0] = 1
	elif i < 800:
		cnt[1] = 1
	elif i < 1200:
		cnt[2] = 1
	elif i < 1600:
		cnt[3] = 1
	elif i < 2000:
		cnt[4] = 1
	elif i < 2400:
		cnt[5] = 1
	elif i < 2800:
		cnt[6] = 1
	elif i < 3200:
		cnt[7] = 1
	else:
		var += 1

print(cnt.count(1), cnt.count(1) + var)
