#include <bits/stdc++.h>
using namespace std;
int main() {
  int people = 0;
  cin >> people;
  int score[people];
  for (int i = 0; i < people; i++) {
    score[i] = 0;
  }
  int countmi = 0, countma = 0;
  int countgr = 0;
  int countch = 0;
  int countg = 0;
  int countw = 0;
  int countb = 0;
  int county = 0;
  int counto = 0;
  int countr = 0;
  int countfree = 0;
  int sum = 0;
  for (int i = 0; i < people; i++) {
    cin >> score[i];
    if (score[i] <= 399 && score[i] >= 1) {
      countgr = 1;
    } else if (score[i] <= 799 && score[i] >= 400) {
      countch = 1;
    } else if (score[i] <= 1199 && score[i] >= 800) {
      countg = 1;
    } else if (score[i] <= 1599 && score[i] >= 1200) {
      countw = 1;
    } else if (score[i] <= 1999 && score[i] >= 1600) {
      countb = 1;
    } else if (score[i] <= 2399 && score[i] >= 2000) {
      county = 1;
    } else if (score[i] <= 2799 && score[i] >= 2400) {
      counto = 1;
    } else if (score[i] <= 3199 && score[i] >= 2800) {
      countr = 1;
    } else if (score[i] >= 3200) {
      countfree += 1;
    }
  }
  countmi =
      countgr + countch + countg + countw + countb + county + counto + countr;
  countma = countmi + countfree;
  cout << countmi << " ";
  cout << countma << endl;
  return 0;
}
