#define _GLIBCXX_DEBUG
#include <bits/stdc++.h>
using namespace std;
#define rep(i, n) for (int i = 0; i < (int)(n); i++)
#define dunk(n) cout << n << endl
#define all(a) (a).begin(),(a).end()
int main() {
    int n;
    cin >> n;
    vector<int> rate(n),color = {0,0,0,0,0,0,0,0};
    rep(i,n) cin >> rate[i];
    sort(all(rate));
    int count = 0,free = 0;
    rep(i,n){
        if(rate[i] < 400) color[0]++;
        else if(rate[i] < 800) color[1]++;
        else if(rate[i] < 1200) color[2]++;
        else if(rate[i] < 1600) color[3]++;
        else if(rate[i] < 2000) color[4]++;
        else if(rate[i] < 2400) color[5]++;
        else if(rate[i] < 2800) color[6]++;
        else if(rate[i] < 3200) color[7]++;
        else free++;
    }
    rep(i,8){
        if(color[i] != 0) count++;
    }
    if(count != 0) cout << count << " " << min(8,count+free) << endl;
    else cout << 1 << " " << min(8,count+free) << endl;
}
}