import numpy as np
n = int(input())
a = list(map(int,input().split()))
w = np.zeros(9,dtype=int)
count = 0
for i in range(n):
    if a[i] < 3200 and w[a[i]//400]==0:
        count+=1
    w[a[i]//400]+=1
if count == 0:
    print(1,w[8])
elif w[7] == 0:
    print(count,count)
else:
    print(count,count+w[8])
print(w[8])