input()
aa = [min(8, int(a) // 400) for a in input().split()]
over3200 = aa.count(8)
colors = len(set(aa))
_min = colors - 1 if over3200 and colors > over3200 else colors
_max = colors + over3200 - 1 if over3200 else colors
print(_min, _max)
