# C - Colorful Leaderboard
N = int(input())
a = list(map(int, input().split()))
DP = [0]*8
tmp = 0

for i in range(N):
    if 1 <= a[i] <= 399:
        DP[0] = 1
    elif 400 <= a[i] <= 799:
        DP[1] = 1
    elif 800 <= a[i] <= 1199:
        DP[2] = 1
    elif 1200 <= a[i] <= 1599:
        DP[3] = 1
    elif 1600 <= a[i] <= 1999:
        DP[4] = 1
    elif 2000 <= a[i] <= 2399:
        DP[5] = 1
    elif 2400 <= a[i] <= 2799:
        DP[6] = 1
    elif 2800 <= a[i] <= 3199:
        DP[7] = 1
    else:
        tmp += 1

ans1 = sum(DP)
ans2 = sum(DP)+tmp
print(ans1,ans2)