N=int(input())
A=list(map(int,input().split(' ')))
colors=[8 if a>=3200 else a//400 for a in A]
c1=[1 if i in colors else 0 for i in range(8)]
c2=colors.count(8)
print(max(1,c1.count(1)),c1.count(1)+c2)