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

A.sort()
irregular_cnt=0
reg_cnt = 0
for i in range(n):
    a = A[i]
    a //= 400
    A[i] = a
    if a>7:
        irregular_cnt += 1

prev = -1

for i in range(n):
    a = A[i]
    if a<8 and prev!=a:
        reg_cnt+=1
        prev = a
if reg_cnt==0 and irregular_cnt>0:    
    print(str(1)+" "+str(min(8, irregular_cnt)))
else:
    print(str(reg_cnt)+" "+str(min(8, reg_cnt+irregular_cnt)))