using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace ABC064C
{
    class Program
    {
        static void Main(string[] args)
        {
            int N = int.Parse(Console.ReadLine());
            string[] vals = Console.ReadLine().Split(' ');

            int hai = 0;
            int cha = 0;
            int midori = 0;
            int mizu = 0;
            int ao = 0;
            int ki = 0;
            int daidai = 0;
            int aka = 0;

            int overR = 0;

            int a;
            for(int i=0; i < N; i++)
            {
                a = int.Parse(vals[i]);

                if(1 <= a && a <= 399)
                {
                    hai = 1;
                }
                else if(400 <= a && a <= 799)
                {
                    cha = 1;
                }
                else if(800 <= a && a <= 1199)
                {
                    midori = 1;
                }
                else if(1200 <= a && a <= 1599)
                {
                    mizu = 1;
                }
                else if(1600 <= a && a <= 1999)
                {
                    ao = 1;
                }
                else if(2000 <= a && a <= 2399)
                {
                    ki = 1;
                }
                else if(2400 <= a && a <= 2799)
                {
                    daidai = 1;
                }
                else if(2800 <= a && a <= 3199)
                {
                    aka = 1;
                }
                else if(3200 <= a)
                {
                    overR++;
                }
            }

            int num = hai + cha + midori + mizu + ao + ki + daidai + aka;

            int max = Math.Min(num + overR, 8);

            if(num == 0 && overR >= 1)
            {
                num = 1;
            }

            Console.WriteLine("{0} {1}", num, max);

        }
    }
}
