n = int(input())
a = list(map(int, input().split()))
from collections import defaultdict
ans = defaultdict(int)
b = 0
for rate in a:
    if rate < 399:
        ans[0] += 1
    elif rate < 799:
        ans[1] += 1
    elif rate < 1199:
        ans[2] += 1
    elif rate < 1599:
        ans[3] += 1
    elif rate < 1999:
        ans[4] += 1
    elif rate < 2399:
        ans[5] += 1
    elif rate < 2799:
        ans[6] += 1
    elif rate < 3199:
        ans[7] += 1
    else:
        b += 1

cnt = 0
for i in ans:
    if i > 0:
        cnt+=1
print(max(cnt,1), cnt+min(7,b))