import sys
n = int(input())
l = [int(i)//400 if int(i)//400 <= 7 else 8 for i in input().split()]
multi = l.count(8)
if multi == 0:
    num_cols = len(set(l))
    print(num_cols, num_cols)
    sys.exit()
    
num_cols = len(set(l)) - 1
min_cols = max(1,num_cols)
max_cols = min(8, num_cols+multi)
print(min_cols, max_cols)