import collections

n = int(input())
a = [int(i) for i in input().split()]

d = collections.defaultdict(int)

for i in a:
    i_ = i // 400
    d[i_] += 1

if 8 in d:
    min_ = max(len(d) - 1, 1)
    max_ = min(len(d) + d[8] - 1, 8)

else:
    min_ = len(d)
    max_ = len(d)

print(min_, max_)