N = int(input())
rates = [int(i) for i in input().split()]

def get_cols(rates):
    col_flags = [False for _ in range(8)]
    wild_colors = 0
    for rate in rates:
        if rate >= 3200:
            wild_colors += 1
        else:
            col_flags[rate // 400] = True
    min_cols = col_flags.count(True)
    max_cols = min_cols + wild_colors
    if max_cols > 8: max_cols = 8
    return (min_cols, max_cols)

print("{} {}".format(*get_cols(rates)))
