N = int(input())
n = [int(i)//400 for i in input().split()]
c = 0
for i in n:
    if i >= 8:
        c += 1
n_kind = [i for i in n if i<8]
print(n_kind)
a = len(set(n_kind))
if a == 0:
    print(1,c)
else:print(a,a+c)
