n = int(input())
A = list(map(int,input().split()))
A.sort()
dict = [0 for _ in range(8)]
B = []
for a in A:
    if 3200 <= a:
        B.append(a)
        continue
    for i in range(8):
        if i*400 <= a and a < (i+1)*400:
            dict[i]+=1
            break
ds = 8-dict.count(0)
maxNum = ds
minNum = ds
if len(B) > 0:
    maxNum += len(B)
print(minNum,maxNum)