#!/usr/bin/env python
# -*- coding: utf-8 -*-

import sys
from collections import deque

n = int(sys.stdin.readline())
ai = list(map(int, sys.stdin.readline().split()))

o = [0] * 9

for a in ai:
	if a < 400:
		o[0] += 1
	elif a < 800:
		o[1] += 1
	elif a < 1200:
		o[2] += 1
	elif a < 1600:
		o[3] += 1
	elif a < 2000:
		o[4] += 1
	elif a < 2400:
		o[5] += 1
	elif a < 2800:
		o[6] += 1
	elif a < 3200:
		o[7] += 1
	else:
		o[8] += 1

on = 0
for i in range(0, 8):
	if o[i] > 0:
		on += 1

min = on
if on < o[8]:
	min = o[8]

on += o[8]
if on > 8:
	on = 8

max = on

print(str(min) + ' ' + str(max))
