import sys
input = sys.stdin.readline

N = int(input())
L = [int(v) // 400 for v in input().split()]
ma = max(L)

if ma < 8:
    s = set(L)
    print(len(s), len(s))
else:
    ml = [v for v in L if v < 8]
    ms = set(ml)
    
    pl = [v for v in L if v >= 8]
    
    if len(ms) == 8:
        print(8, 8)
    else:
        t = len(ms) + len(pl)
        
        if t >= 8:
            print(8, 8)
        else:
            mm = len(ms)
            print(mm if mm != 0 else 1, t)
