n = int(input())
rates = list(map(int,input().split()))
coler = []
for i in range(n):
    if  0<= rates[i] <=399 :
        coler.append("1")
    elif 400 <= rates[i] <= 799:
        coler.append("2")
    elif  800<= rates[i] <=1199 :
        coler.append("3")
    elif  1200<= rates[i] <=1599 :
        coler.append("4")
    elif  1600<= rates[i] <=1999 :
        coler.append("5")
    elif  2000<= rates[i] <=2399 :
        coler.append("6")
    elif  2400<= rates[i] <=2799 :
        coler.append("7")
    elif  2800<= rates[i] <=3199 :
        coler.append("8")    
    else:
        coler.append("all")
jud = set(coler)
if "all" not in jud:
    print(len(jud),len(jud))
else:
    if len(jud) == 9:
        print(8,8)
    else:
        print(max(1,len(jud)-1),min(8,(coler.count("all")) + len(jud) -1))


