N = int(input())
a = [i // 400 for i in map(int, input().split())]
min_a = sum(i < 8 for i in set(a))
max_a = min(8, min_a + sum(i >= 8 for i in a))
if min_a == 0:
    print(1, max_a)
else:
    print(min_a, max_a)