N = int(input())
a = list(map(int,input().split()))

color = [0 for j in range(9)]

for i in range(N):
    if a[i] >= 3200:
        color[8] += 1
    else:
        for j in range(8):
            if a[i] // 400 == j:
                color[j] += 1

color_min = 8 - color[:8].count(0)
if 8 - color_min <= color[8]:
    if color_min == 0:
        color_min = 1
    color_max = 8
else:
    color_max = color_min + color[8]
print(color_min, color_max)