n = int(input())
listA = list(map(int, input().split()))
colorL = [0, 0, 0, 0, 0, 0, 0, 0]
min=0
max=0
index=0
while index < len(listA):
    if listA[index] >0 and listA[index]<400 and colorL[0]==0:
        colorL[0]=1
        min+=1
        max+=1
    elif listA[index] >399 and listA[index]<800 and colorL[1]==0:
        colorL[1]=1
        min += 1
        max += 1
    elif listA[index] > 799 and listA[index] < 1200 and colorL[2] == 0:
        colorL[2] = 1
        min += 1
        max += 1
    elif listA[index] > 1199 and listA[index] < 1600 and colorL[3] == 0:
        colorL[3] = 1
        min += 1
        max += 1
    elif listA[index] > 1599 and listA[index] < 2000 and colorL[4] == 0:
        colorL[4] = 1
        min += 1
        max += 1
    elif listA[index] > 1999 and listA[index] < 2400 and colorL[5] == 0:
        colorL[5] = 1
        min += 1
        max += 1
    elif listA[index] > 2399 and listA[index] < 2800 and colorL[6] == 0:
        colorL[6] = 1
        min += 1
        max += 1
    elif listA[index] > 2799 and listA[index] < 3200 and colorL[7] == 0:
        colorL[7] = 1
        min += 1
        max += 1
    elif listA[index] > 3199:
        max+=1
    index+=1

print(str(min)+" "+str(max))
