bound = [3200, 2800, 2400, 2000, 1600, 1200, 800, 400, 1]
d = {b: 0 for b in bound}

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

for a in A:
    for b in bound:
        if b <= a:
            d[b] += 1
            break

mini = 0
for b in bound[1:]:
    if d[b] > 0:
        mini += 1

print(mini, mini + d[3200])
