#include <bits/stdc++.h>
using namespace std;
long long int MOD = (1e9) + 7;
void fastIO() {
  ios_base::sync_with_stdio(0);
  cin.tie(0);
}
int main() {
  fastIO();
  int n;
  cin >> n;
  vector<int> score(n);
  for (int i = 0; i < n; i++) {
    cin >> score[i];
  }
  int cnt = 0, ans = 0;
  bool gray = false, brown = false, green = false, cyan = false, blue = false,
       yellow = false, orange = false, red = false;
  for (int i = 0; i < n; i++) {
    if (score[i] <= 399 && !gray) {
      gray = true;
      ans++;
    } else if (score[i] > 399 && score[i] <= 799 && !brown) {
      brown = true;
      ans++;
    } else if (score[i] > 799 && score[i] <= 1199 && !green) {
      green = true;
      ans++;
    } else if (score[i] > 1199 && score[i] <= 1599 && !cyan) {
      cyan = true;
      ans++;
    } else if (score[i] > 1599 && score[i] <= 1999 && !blue) {
      blue = true;
      ans++;
    } else if (score[i] > 1999 && score[i] <= 2399 && !yellow) {
      yellow = true;
      ans++;
    } else if (score[i] > 2399 && score[i] <= 2799 && !orange) {
      orange = true;
      ans++;
    } else if (score[i] > 2799 && score[i] < 3200 && !red) {
      red = true;
      ans++;
    } else if (score[i] >= 3200) {
      cnt++;
    }
  }
  cout << ans << " " << cnt + ans << endl;
}
