from collections import Counter

N = int(input())
a = list(map(int, input().split()))
late = Counter(list(map(lambda a: a//400, a)))

count = 0
for key in [0,1,2,3,4,5,6,7]:
    if late[key] == 0:
        count += 1

max_a = min_a = 8-count
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)