N = int(input())
a = sorted([int(i)//400 for i in input().split()])
k = a.count(8)
minn = len(set(a))
ans = []
ans.append(minn)
if k >= 1:
    maxn = minn - 1 + k
else:
    maxn = minn
ans.append(maxn)
print(*ans)