N = int(input())

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

cnt = {}
for score in scores:
    key = score // 400
    cnt.setdefault(key, 0)
    cnt[key] += 1
    
print(cnt)
colors = len(cnt.keys())
             
if 8 in cnt.keys():
    if colors == 1:
        min_color = colors
    else :
        min_color = colors - 1
    max_color = colors + cnt[8] -1 
else :
    min_color = colors
    max_color = colors
    
if max_color >= 8:
    max_color = 8
    
print(min_color, max_color)