#define _USE_MATH_DEFINES
#include <bits/stdc++.h>
using namespace std;

#define rep(i, n) REP(i, 0, n)
#define ALL(v) v.begin(), v.end()
#define MSG(a) cout << #a << " " << a << endl;
#define REP(i, x, n) for (int i = x; i < n; i++)
#define OP(m) cout << m << endl
typedef long long ll;
typedef unsigned long long ull;

int main()
{
    int n;
    cin >> n;

    bool s[8];
    int cnt = 0, f = 0;
    rep(i, n)
    {
        int a;
        cin >> a;
        if (1 <= a && a <= 399 && !s[0])
        {
            s[0] = 1;
            cnt++;
        }
        if (400 <= a && a <= 799 && !s[1])
        {
            s[1] = 1;
            cnt++;
        }
        if (800 <= a && a <= 1199 && !s[2])
        {
            s[2] = 1;
            cnt++;
        }
        if (1200 <= a && a <= 1599 && !s[3])
        {
            s[3] = 1;
            cnt++;
        }
        if (1600 <= a && a <= 1999 && !s[4])
        {
            s[4] = 1;
            cnt++;
        }
        if (2000 <= a && a <= 2399 && !s[5])
        {
            s[5] = 1;
            cnt++;
        }
        if (2400 <= a && a <= 2799 && !s[6])
        {
            s[6] = 1;
            cnt++;
        }
        if (2800 <= a && a <= 3199 && !s[7])
        {
            s[7] = 1;
            cnt++;
        }
        if (a >= 3200)
            free++;
    }

    cout << cnt << " " << min(8, cnt + free) << endl;

    return 0;
}