
N = int(input())
a = [int(e) for e in input().split()]

def colors(score):
    if score < 400:
        return 1
    elif score < 800:
        return 2
    elif score < 1200:
        return 3
    elif score < 1600:
        return 4
    elif score < 2000:
        return 5
    elif score < 2400:
        return 6
    elif score < 2800:
        return 7
    elif score < 3200:
        return 8
    elif score >= 3200:
        return 0

ary = [colors(s) for s in a]
ary_n = set(ary)

if not 0 in ary_n:
    n_min = len(ary_n)
    n_max = len(ary_n)
else:
    n_zero = sum([e == 0 for e in ary])
    n_min = len(ary_n) - 1
    n_max = len(ary_n) + n_zero - 1

print(n_min, n_max)
