N = int(input())
R = [(int(i)//400) for i in input().split()]
S = set()
f = 0
for i in R:
    if i < 8:
        S.add(i)
    else:
        f += 1

t = max(1,len(S)) 
mx = min(len(S)+f, 8)
print(t,mx)
