n = int(input())
colors = [0]*9

A = map(int, input().split())
for i in A:
    if 1 <= i <= 399:
        colors[1] = 1
    elif 400 <= i <= 799:
        colors[2] = 1
    elif 800 <= i <= 1199:
        colors[3] = 1
    elif 1200 <= i <= 1599:
        colors[4] = 1
    elif 1600 <= i <= 1999:
        colors[5] = 1
    elif 2000 <= i <= 2399:
        colors[6] = 1
    elif 2400 <= i <= 2799:
        colors[7] = 1
    elif 2800 <= i <= 3199:
        colors[8] = 1
    else:
        colors[0] += 1

s = sum(colors[1:9]) + colors[0]
if s <= 8:
    print(s-colors[0], s)
else:
    print(s-colors[0], 8)