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

co = [1,400,800,1200,1600,2000,2400,2800, 3200]

from collections import defaultdict
from bisect import bisect_right

ans = 0
gold = 0
dic = defaultdict(int)
for i in range(N):
    r = bisect_right(co, A[i])
    dic[r] += 1
    
gold = dic[9]
del dic[9]
ans = len(dic.keys())

print( ans  , min(ans+gold, 8) )

