#include <bits/stdc++.h>
using namespace std;
int main() {
  int n;
  cin >> n;
  int countover = 0;
  vector<bool> flg(9, false);
  for (int i = 0; i < n; i++) {
    int x;
    cin >> x;
    if (1 <= x && x < 400)
      flg[0] = true;
    else if (400 <= x && x < 800)
      flg[1] = true;
    else if (800 <= x && x < 1200)
      flg[2] = true;
    else if (1200 <= x && x < 1600)
      flg[3] = true;
    else if (1600 <= x && x < 2000)
      flg[4] = true;
    else if (2000 <= x && x < 2400)
      flg[5] = true;
    else if (2400 <= x && x < 2800)
      flg[6] = true;
    else if (2800 <= x && x < 3200)
      flg[7] = true;
    else if (3200 <= x) {
      flg[8] = true;
      countover++;
    }
  }
  int count = 0;
  for (int i = 0; i < 8; i++) {
    if (flg[i]) count++;
  }
  int countmax = min(8, count + countover);
  if (count == 0 && countover != 0) count = 1;
  cout << count << " " << countmax;
  return 0;
}
