import numpy as np
N = int(input())
a_list = list(map(int, input().split()))
class_list = []
free_list = []
for a in a_list:  
  if a < 3200:
    amod = a // 400
    class_list.append(amod)
  
  else:
    free_list.append(a)

print(class_list)
print(free_list)

set_list = list(set(class_list))

print(len(set_list), len(set_list) + len(free_list))

    

  

