n=int(input())

t = list(map(int,input().split()))

memo = [0]*9

for i in t:
    if 1<= i and i<400:
        memo[0] += 1
    elif 400<= i and i<800:
        memo[1] += 1
    elif 800<= i and i<1200:
        memo[2] += 1
    elif 1200<= i and i<1600:
        memo[3] += 1
    elif 1600<= i and i<2000:
        memo[4] += 1
    elif 2000<= i and i<2400:
        memo[5] += 1
    elif 2400<= i and i<2800:
        memo[6] += 1
    elif 2800<= i and i<3200:
        memo[7] += 1
    else:
        memo[8] += 1

ans = 0

for i in range(len(memo)):
    if i == 8:
        ex = memo[-1]
    elif memo[i] != 0:
        ans += 1

print(ans, ans+ex)
    