n = int(input())
a = list(map(int, input().split()))
li = [0]*15
tourist = 0

for i in a:
    if i // 400 >= 8:
        tourist += 1

    if li[i//400] == 0:
        li[i//400] = 1

minrate = sum(li[:8])
maxrate = minrate + tourist

print(minrate, maxrate)