n = int(input())
al = list(map(int, input().split()))

ald = list(map(lambda x : x // 400,al))

allow = list(filter(lambda x: x<8, ald))
reslow = len(set(allow))

alhigh= list(filter(lambda x: x>=8,ald))
reshigh = len(alhigh)

res = min((reslow+reshigh),8)
print(reslow,res)