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

int main(){
  int n;
  cin >> n;
  vector<int> a(n);
  vector<int> b(9);
  for(int i = 0; i < n; i++){
    cin >> a.at(i);
    if(a.at(i) < 400){
      b.at(0)++;
    }else if(a.at(i) >= 400 && a.at(i) < 800){
      b.at(1)++;
    }else if(a.at(i) >= 800 && a.at(i) < 1200){
      b.at(2)++;
    }else if(a.at(i) >= 1200 && a.at(i) < 1600){
      b.at(3)++;
    }else if(a.at(i) >= 1600 && a.at(i) < 2000){
      b.at(4)++;
    }else if(a.at(i) >= 2000 && a.at(i) < 2400){
      b.at(5)++;
    }else if(a.at(i) >= 2400 && a.at(i) < 2800){
      b.at(6)++;
    }else if(a.at(i) >= 2800 && a.at(i) < 3200){
      b.at(7)++;
    }else if(a.at(i) >= 3200){
      b.at(8)++;
    }
  }
  int c = 0;
  for(int i = 0; i < 9; i++){
    if(b.at(i) >= 1){
      c++;
    }
  }
  int comin, comax;
  if(b.at(8) == 0){
    comin = c;
    comax = c;
  }else(b.at(8) >= 1){
    if(c == 0){
      comin = 1;
      comax = min(8, b.at(8));
    }else{
      comin = c;
      comax = min(8, c+b.at(8));
    }
  }
  cout << comin << " " << comax << endl;
}
