N = int(input())
a = [int(i) for i in input().split()]
ls = [0]*9
b = [1,400,800,1200,1600,2000,2400,2800,3200,4801]
for i in range(N):
    for j, (x, y) in enumerate(zip(b, b[1:])):
        if x <= a[i] and a[i] < y:
            ls[j] += 1
l = 8 - ls[:-1].count(0)
h = l + min(ls[:-1].count(0), ls[-1])
print(l, h)