import sys
input=sys.stdin.readline

def atc(atc):
    result=["1","2","3","4","5","6","7","8","9","9","9","9","9","9","9","9","9"][atc//400]
    return result
num=0
L1=[]
n=int(input())
L=list(map(int,input().split()))
for i in L:
    a=atc(i)
    if a=="9":
        num+=1
    else:L1.append(a)
b=len(set(L1))
c=b+num
print(b,c)