import sys
input = sys.stdin.readline

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

t = set()
c = 0
for v in L:
    if v >= 8:
        c += 1
    else:
        t.add(v)
        
cc = len(t)
if cc == 0:
    print(1, c)
elif c == 0:
    print(cc, cc)
else:
    tt = c + cc
    if tt >= 8:
        print(cc, 8)
    else:
        print(cc, tt)