#include <bits/stdc++.h>
using namespace std;
using P = pair<int, int>;
long long mod = 1000000007;
int main() {
  int n;
  cin >> n;
  vector<int> a(n);
  for (int i = 0; i < n; i++) cin >> a[i];
  vector<int> b(9);
  for (int i = 0; i < n; i++) {
    if (a[i] <= 399)
      b[0]++;
    else if (400 <= a[i] && a[i] <= 799)
      b[1]++;
    else if (800 <= a[i] && a[i] <= 1199)
      b[2]++;
    else if (1200 <= a[i] && a[i] <= 1599)
      b[3]++;
    else if (1200 <= a[i] && a[i] <= 1999)
      b[4]++;
    else if (2000 <= a[i] && a[i] <= 2399)
      b[5]++;
    else if (2400 <= a[i] && a[i] <= 2799)
      b[6]++;
    else if (2800 <= a[i] && a[i] <= 3199)
      b[7]++;
    else if (3200 <= a[i])
      b[8]++;
  }
  int ans = 0;
  if (b[8] == 0) {
    for (int i = 0; i < 9; i++) {
      if (b[i] != 0) {
        ans++;
      }
    }
    cout << ans << ' ' << ans << endl;
    return 0;
  }
  int cnt = 0;
  if (b[8] != 0) {
    for (int i = 0; i < 8; i++) {
      if (b[i] == 0) {
        cnt++;
      }
    }
    ans = 8 - cnt + min(b[8], cnt);
    cout << 8 - cnt << ' ' << ans << endl;
    return 0;
  }
}
