n=int(input())
r=list(map(int,input().split()))
rlist=[]
def color(n):
    if n<400:
        return 1
    elif n<800:
        return 2
    elif n<1200:
        return 3
    elif n<1600:
        return 4
    elif n<2000:
        return 5 
    elif n<2400:
        return 6 
    elif n<2800:
        return 7 
    elif n<3200:
        return 8 
    else:
        return 9

for _ in range(n):
    co=color(r[_])
    rlist.append(co)

ans1=len(set(rlist))
if rlist.count(9)==0:
    print(ans1,ans1,sep=" ")

elif ans1=1:
    print(1,min(8,rlist.count(9),sep=" ")

else:
    print(min(8,ans1-1),min(8,ans1-1+rlist.count(9)),sep=" ")