from bisect import bisect_left

N = int(input())
a = sorted(list(map(int, input().split())))
ans = 0
max_ans = 0
c = 0
if bisect_left(a, 400):
  ans += 1
  c = bisect_left(a, 400)
if c != bisect_left(a, 800):
  ans += 1
  c = bisect_left(a, 800)
if c != bisect_left(a, 1200):
  ans += 1
  c = bisect_left(a, 1200)
if c != bisect_left(a, 1600):
  ans += 1
  c = bisect_left(a, 1600)
if c != bisect_left(a, 2000):
  ans += 1
  c = bisect_left(a, 2000)
if c != bisect_left(a, 2400):
  ans += 1
  c = bisect_left(a, 2400)
if c != bisect_left(a, 2800):
  ans += 1
  c = bisect_left(a, 2800)
if c != bisect_left(a, 3200):
  ans += 1
  c = bisect_left(a, 3200)
  max_ans += ans + N - c

print(ans, max_ans if max_ans else ans)