N = int(input())
a = list(map(int,input().split()))
rl = [0] * 9
for c in a:
    if c>=3200:rl[0] += 1
    elif c>=2800:rl[1] = 1
    elif c >= 2400:rl[2] = 1
    elif c >= 2000:rl[3] = 1
    elif c >= 1600:rl[4] = 1
    elif c >= 1200:rl[5] = 1
    elif c >=  800:rl[6] = 1
    elif c >=  400:rl[7] = 1
    else:rl[7] = 1
print(sum(rl[1:]),sum(rl))