def f(x):
    if x < 400:
        return 0
    elif x < 800:
        return 1
    elif x < 1200:
        return 2
    elif x < 1600:
        return 3
    elif x < 2000:
        return 4
    elif x < 2400:
        return 5
    elif x < 2800:
        return 6
    elif x < 3200:
        return 7
    else:
        return 8

import sys
input = sys.stdin.readline
N = int(input())
a = list(map(int, input().split()))
dic, c = {}, 0
for i in range(N):
    b = f(a[i])
    if b not in dic:
        dic[b] = 1
    if b == 8:
        c += 1
m, M = len(dic.keys()), len(dic.keys())
if 8 in dic:
    m -= 1
    M += dic[8]
print(m, M)