

import numpy as np
import fractions as fra


input()
s=set()
c=0
for y in input().split():
    x=int(y)//400
    if(x>=8):
        c+=1
    else:
        s.add(x)

#print(s)
ls=len(s)
print(ls,end=" ")
print(ls+c)