N = int(input())
A = [int(i) for i in input().split()]

flg = [0,0,0,0,0,0,0,0,0]
for i in range(len(A)):
    if   A[i] <  400: flg[0] = 1
    elif A[i] <  800: flg[1] = 1
    elif A[i] < 1200: flg[2] = 1
    elif A[i] < 1600: flg[3] = 1
    elif A[i] < 2000: flg[4] = 1
    elif A[i] < 2400: flg[5] = 1
    elif A[i] < 2800: flg[6] = 1
    elif A[i] < 3200: flg[7] = 1
    else:             flg[8] += 1

colmin = max(sum(flg[0:8]), 1)
colmax = min(sum(flg), 8)
print(colmin, colmax)

