n = int(input())
a = [int(x) for x in input().split()]

agg = [0] * 9
free = 0

for rate in a:
    if rate < 400:
        agg[0] += 1
    elif rate < 800:
        agg[1] += 1
    elif rate < 1200:
        agg[2] += 1
    elif rate < 1600:
        agg[3] += 1
    elif rate < 2000:
        agg[4] += 1
    elif rate < 2400:
        agg[5] += 1
    elif rate < 2800:
        agg[6] += 1
    elif rate < 3200:
        agg[7] += 1
    else:
        agg[8] += 1

minimum = len([x for x in agg if x > 0])
maximum = minimum + max(agg[8]-1, 0)

print(minimum, maximum)