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

Ans = 0
Cnt = [0]*9
for i in range(N):
    if A[i]>3200:
        A[i] = 3200
    Cnt[A[i]//400] += 1

for i in range(8):
    if Cnt[i]>0:
        Ans += 1

print(Ans, min(Ans+Cnt[8], 9))