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

free = 0
colors = {}

for a in A:
    if a < 3200:
        ai = a // 400
        if not ai in colors:
            colors[ai] = True

    else:
        free += 1

print(min(8, len(colors)), min(8, len(colors) + free))