#include <bits/stdc++.h>
using namespace std;
const double eps = 0.000000001;
const int MOD = 1000000009;
const int N = 100005;
int a[N];
bool b[10];
int main() {
  int n, cnt = 0;
  cin >> n;
  for (int i = 1; i <= n; i++) cin >> a[i];
  for (int i = 1; i <= n; i++) {
    if (a[i] >= 3200)
      cnt++;
    else if (a[i] <= 399)
      b[1] = true;
    else if (a[i] <= 799)
      b[2] = true;
    else if (a[i] <= 1199)
      b[3] = true;
    else if (a[i] <= 1599)
      b[4] = true;
    else if (a[i] <= 1999)
      b[5] = true;
    else if (a[i] <= 2399)
      b[6] = true;
    else if (a[i] <= 2799)
      b[7] = true;
    else if (a[i] <= 3199)
      b[8] = true;
  }
  int mn = 0, mx = 0;
  for (int i = 1; i <= 8; i++) mn += b[i];
  mx = mn + cnt;
  mx = min(mx, 8);
  mn = max(mn, 1);
  cout << mn << " " << mx << endl;
  return 0;
}
