#include <bits/stdc++.h>
using namespace std;
int gcd(int a, int b) {
  if (a % b == 0) {
    return (b);
  } else {
    return (gcd(b, a % b));
  }
}
int lcm(int a, int b) { return a * b / gcd(a, b); }
bool primenum(int a) {
  if (a == 1) {
    return false;
  }
  if (a == 2) {
    return true;
  }
  if (a % 2 == 0) {
    return false;
  }
  for (int i = 3; i < sqrt(a) + 1; i += 2) {
    if (a != i) {
      if (a % i == 0) {
        return false;
      }
    }
  }
  return true;
}
struct setupios {
  setupios() {
    ios::sync_with_stdio(0);
    cin.tie(nullptr);
  };
} setupios;
int main() {
  int n;
  cin >> n;
  vector<bool> colors(8, false);
  int kansuto = 0;
  int ans = 0;
  for (long long i = 0; i < n; i++) {
    int a;
    cin >> a;
    if (a / 400 >= 8) {
      kansuto++;
    } else {
      if (!colors[a / 400]) {
        colors[a / 400] = true;
        ans++;
      }
    }
  }
  cerr << kansuto << " " << ans << endl;
  {
    int diff = kansuto - ans;
    if (diff > 0) {
      if (diff + ans > 8)
        cout << 8 << endl;
      else
        cout << diff + ans << " ";
    } else {
      cout << ans << " ";
    }
  }
  {
    if (ans + kansuto > 8) {
      cout << 8 << endl;
    } else {
      cout << ans + kansuto << endl;
    }
  }
}
