#include<iostream>
using namespace std;

int n, buf, emp = 0, p = 0;
int color[9] = {0,0,0,0,0,0,0,0,0};

int main(){
    cin >> n;
    for(int i = 0; i < n; i++){
        cin >> buf;
        if(buf < 400){
            color[0]++;
        }else if(buf < 800){
            color[1]++;
        }else if(buf < 1200){
            color[2]++;
        }else if(buf < 1600){
            color[3]++;
        }else if(buf < 2000){
            color[4]++;
        }else if(buf < 2400){
            color[5]++;
        }else if(buf < 2800){
            color[6]++;
        }else if(buf < 3200){
            color[7]++;
        }else{
            color[8]++;
        }
    }
    for(int j = 0; j < 8; j++){
        if(color[j] == 0){
            emp++;
        }
    }
    if(emp == 8) p = 1;
    if(color[8] == 0){
        cout << 8 - emp << " " << 8 - emp << endl;
    }else(color[8] < emp){
        cout << 8 - emp + p << " " << 8 - emp + color[8] << endl;
    }
}