n = int(input())
l = list(map(int,input().split()))
color = [0]*10
ans = 0
aans = 0
for i in range(n):
    if l[i] >= 3200:
        aans += 1
    else:
        color[int(l[i]/400)] += 1
print(color)
for i in color:
    if i > 0:
        ans += 1
if aans == n:
    print(1,n)
else:
    print(ans,aans+ans)
