N = int(input())
rank = list(map(int, input().split()))
color = [0 for i in range(8)]
for i in range(len(rank)):
    for j in range(len(color)):
        if 400 * j <= int(rank[i]) < 400 * (j + 1):
            color[j] += 1
            break
count = N - sum(color)
print(len(color) - color.count(0), len(color) - color.count(0) + count)
