n=int(input())
mark=[i for i in range(0,3200,400)]
mark.append(99999999999999)
def color(x):
    for i in range(9):
        if mark[i]<=x<mark[i+1]:
            return i     
score=list(map(int,input().split()))
set=set([])
special=0
for x in score:
    if x<3200:
        set.add(color(x))
    else:
        special+=1
        
print(max(len(set),1),min(8,len(set)+special))