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

color=[False]*8
count=0

for aa in a:
    index=aa//400 -1
    if index>=8:
        count+=1
    else:
        color[index]=True

print("{} {}".format(color.count(True), min(8,color.count(True)+count)))
        