#ifdef DEBUG

#else

#    pragma GCC optimize("O3,no-stack-protector")
#    pragma GCC optimize("unroll-loops")

#    if __cplusplus < 201703L
#        pragma GCC target("avx")
#    else
#        pragma GCC target("avx2")
#    endif

#endif
// 実数の場合
// #pragma GCC target("sse,sse2,sse3,ssse3,sse4,popcnt,abm,mmx,avx,tune=native")

#define _USE_MATH_DEFINES
#include <bits/stdc++.h>
#define dump(x) cout << x << endl
typedef int64_t Int;
typedef long double Ld;

using namespace std;
using Graph = vector<vector<Int>>;

const double pi = M_PI;
const Int MOD = 1000000007;

int main() {
    ios::sync_with_stdio(false);
    cin.tie(nullptr);

    vector<int> c(9);
    int n;
    cin >> n;
    for (int i = 0; i < n; i++) {
        int a;
        cin >> a;

        if (a <= 399) {
            c[0]++;
        } else if (a <= 799) {
            c[1]++;
        } else if (a <= 1199) {
            c[2]++;
        } else if (a <= 1599) {
            c[3]++;
        } else if (a <= 1999) {
            c[4]++;
        } else if (a <= 2399) {
            c[5]++;
        } else if (a <= 2799) {
            c[6]++;
        } else if (a <= 3199) {
            c[7]++;
        } else {
            c[8]++;
        }
    }

    int ansmin = 0, ansmax = 0;
    for (int i = 0; i < 8; i++) {
        if (c[i] != 0) {
            ansmin++;
        }
    }
    ansmax += ansmin;
    if (c[8] != 0) {
        ansmax += min(8 - ansmin, c[8], 8);
    }

    cout << ansmin << ' ' << ansmax << endl;

    return 0;
}
