n = int(input())
ai = list(map(int,input().split()))
aj = list(map(lambda x:int(x/400),ai))
print(aj)
rainbow = 0
for e in aj:
  if e >= 8:
    rainbow += 1
ak= set(aj)
ans = 0
for e in ak:
  if e < 8:
    ans += 1
print(max(1,ans) ,end='')
print(' ' ,end = '')
print(ans+ rainbow)