#include <bits/stdc++.h>
using namespace std;
signed main() {
  int N;
  cin >> N;
  vector<int> vec(N);
  for (int i = 0; i < N; i++) {
    cin >> vec.at(i);
  }
  int A = 0;
  int B = 0;
  int C = 0;
  int D = 0;
  int E = 0;
  int F = 0;
  int G = 0;
  int H = 0;
  int I = 0;
  for (int i = 0; i < N; i++) {
    if (vec.at(i) < 400) {
      A++;
    } else if (vec.at(i) < 800) {
      B++;
    } else if (vec.at(i) < 1200) {
      C++;
    } else if (vec.at(i) < 1600) {
      D++;
    } else if (vec.at(i) < 2000) {
      E++;
    } else if (vec.at(i) < 2400) {
      F++;
    } else if (vec.at(i) < 2800) {
      G++;
    } else if (vec.at(i) < 3200) {
      H++;
    } else {
      I++;
    }
  }
  bool AA = false;
  bool BB = false;
  bool CC = false;
  bool DD = false;
  bool EE = false;
  bool FF = false;
  bool GG = false;
  bool HH = false;
  if (A != 0) {
    AA = true;
  }
  if (B != 0) {
    BB = true;
  }
  if (C != 0) {
    CC = true;
  }
  if (D != 0) {
    DD = true;
  }
  if (E != 0) {
    EE = true;
  }
  if (F != 0) {
    FF = true;
  }
  if (G != 0) {
    GG = true;
  }
  if (H != 0) {
    HH = true;
  }
  int cnt = 0;
  if (AA == true) {
    cnt++;
  }
  if (BB == true) {
    cnt++;
  }
  if (CC == true) {
    cnt++;
  }
  if (DD == true) {
    cnt++;
  }
  if (EE == true) {
    cnt++;
  }
  if (FF == true) {
    cnt++;
  }
  if (GG == true) {
    cnt++;
  }
  if (HH == true) {
    cnt++;
  }
  if (I != 0) {
    if (cnt == 0) {
      cout << 1 << " " << min(I, 8) << endl;
    } else {
      cout << cnt << " " << min(cnt + I, 8) << endl;
    }
  } else {
    cout << cnt << " " << cnt << endl;
  }
}
