n = int(input())
A = list(map(int, input().split()))
colors = 0
for i in range(8):
    colors += any(i * 400 <= a < (i + 1) * 400 for a in A)
print(colors,end=' ')
colors += sum((i + 1) * 400 <= a for a in A)
print(colors)