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

late = [0 for i in range(9)]

for n in a:
    late[n//400] += 1

max_a = min_a = 8-late[:-1].count(0)
if late[8] and not min_a:
    min_a = 1

if late[8]:
    max_a = min(max_a+late[8], 8)

print(min_a, max_a)