
N = int(input())
A = list(map(int,input().split()))
colors = [0] * 9
for a in A:
  index = min(a // 400,8)
  colors[index] += 1
min_color = max(sum([1 for c in colors[:-1] if c != 0]),1)
max_color = min(min_color+colors[-1]-1,8)
print(min_color,max(min_color,max_color))
 