def resolve():
    n = int(input())
    a = list(map(int, input().split()))
    over3200 = len([ai for ai in a if ai >= 3200])
    c = set([ai // 400 for ai in a if ai < 3200])
    print(max(1, len(c)), min(len(c) + over3200, 8))


if __name__ == "__main__":
    resolve()
