#include <bits/stdc++.h>
#include <boost/range/irange.hpp>
#include <boost/range/adaptors.hpp>

using namespace std;
using namespace boost;
using namespace boost::adaptors;
using uint = unsigned int;
using ll = long long int;
using ull = unsigned long long int;


uint rate(ll k){
    if (k < 400) return 0;
    else if (k < 800) return 1;
    else if (k < 1200) return 2;
    else if (k < 1600) return 3;
    else if (k < 2000) return 4;
    else if (k < 2400) return 5;
    else if (k < 2800) return 6;
    else if (k < 3200) return 7;
    else return 8;
}

int main() {
    array<ll, 9> rates{0};
    ll N;
    cin >> N;
    for (auto &&i: irange(0LL, N)){
        ll k;
        cin >> k;
        rates.at(rate(k))++;
    }
    ll count{0};
    for (auto &&i: irange(0LL, 8LL)){
        if (rates.at(i) != 0) count++;
    }
    cout << ((count == 0) ? (rates.at(8)==0 ? 0 : 1) : count) << " ";
    cout << min(8LL, count + rates.at(8)) << endl;

    return 0;
}