def rating(n):
    if 1<=n<=399:return 0
    elif 400<=n<=799:return 1
    elif 800<=n<=1199:return 2
    elif 1200<=n<=1599:return 3
    elif 1600<=n<=1999:return 4
    elif 2000<=n<=2399:return 5
    elif 2400<=n<=2799:return 6
    elif 2800<=n<=3199:return 7
    else:return 8

N=int(input())
A=list(map(int,input().split()))
B=[]
for a in A:B.append(rating(a))
wild=B.count(8)
b=len(list(set(B)))
if wild==0:print(b,b)
else:print(b-1,min(8,b+1))