n = int(input())
a = [int(i) for i in input().split()]
col = [0 for i in range(n)]
cnt = 0
for i in range(n):
    if 1 <= a[i] <=399:
        col[i] = "b"
    elif 400<= a[i]<=799:
        col[i] = "c"
    elif 800<= a[i]<=1199:
        col[i] = "d"
    elif 1200<= a[i]<=1599:
        col[i] = "e"
    elif 1600<= a[i]<=1999:
        col[i] = "f"
    elif 2000<= a[i]<=2399:
        col[i] = "g"
    elif 2400<= a[i]<=2799:
        col[i] = "h"
    elif 2800<= a[i]<=3199:
        col[i] = "j"
    else:
        col[i] = "k"
        cnt += 1
colv = list(set(col))
mn =mx = len(colv)
if "k" in colv:
        mn -=1
        mx += cnt-1
        if mn == 0:
            mn =1
        if mx >=8:
            mx =8
print(str(mn)+" "+str(mx))