N = int(input())
A = list(map(int,input().split()))
A = [e//400 for e in A]
from collections import Counter
D = Counter(A)
ans = 0
add = 0
for key,value in D.items():
    if key >= 8:
        add += value
    else:
        if value > 0:
            ans += 1
print(ans,ans+add)