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

color = [False for _ in range(8)]
x = 0
for a in A:
    if a >= 3200:
        x += 1
    else:
        tmp = a // 400
        color[tmp] = True

print(color.count(True), color.count(True) + x)