def color(r):
  if r<3200:return r//400
  else:return 8
colors = [0]*9
N=int(input())
for a in map(int,input().split()):
  colors[color(a)]+=1
base=0
for i n range(8):
  if colors[i]>0:base+=1
print(base, base+colors[8])