#include <cstdlib>
#include <climits>
#include <iostream>
#include <cstdint>
#include <vector>
#include <string>
#include <complex>
#include <bitset>
#include <queue>
#include <deque>
#include <stack>
#include <utility>
#include <set>
#include <map>
#include <unordered_set>
#include <unordered_map>

#include <boost/lexical_cast.hpp>
#include <boost/algorithm/string.hpp>
#include <boost/multi_array.hpp>

using namespace std;

int main()
{
    int N;
    std::cin >> N;

    std::vector<int> A;
    for (size_t i = 0; i < N; ++i) {
        int t;
        std::cin >> t;
        A.push_back(t);
    }


    constexpr std::pair<int, int> range[] =
    {{1,399},
     {400,799},
     {800,1199},
     {1200,1599},
     {1600,1999},
     {2000,2399},
     {2400,2799},
     {2800,3199}};

    int col = 0;
    for (auto&& r: range) {
        auto pos = std::find_if(std::begin(A), std::end(A), [r](int a) {
                return r.first <= a && a <= r.second;
            });
        if (pos != std::end(A)) {
            col++;
        }
    }

    auto n = std::count_if(std::begin(A), std::end(A), [](int a) {
            return 3200 <= a;
        });

    std::cout << std::min(col, 1) << " " << col + n << std::endl;

    return 0;
}
