import sys

def main():
    N = int(input())
    a = list(map(int, input().split()))
    colors = [0] * 9 # 8色 + 任意の1色
    for rate in a:
        colors[min(rate // 400, 8)] += 1

    mn = 0
    for c in colors[0:8]:
        if c != 0:
            mn += 1

    mx = mn + min(8 - mn, colors[8])
    print(mn, mx)

if __name__ == "__main__":
    main()