#include <algorithm>
#include <cmath>
#include <iostream>
#include <map>
#include <numeric>
#include <queue>
#include <set>
#include <vector>
#define rep(i, f, n) for (int i = (f); i < (int)(n); i++)
#define repe(i, f, n) for (int i = (f); i <= (int)(n); i++)
#define accum(x) accumulate((x).begin(), (x).end(), 0)
using namespace std;
using ll = long long;
using pint = pair<int, int>;

const int COLORS = 8;

int main() {
  int n, a, free = 0;
  cin >> n;
  vector<int> v(COLORS);
  rep(i, 0, n) {
    cin >> a;
    int color;
    if (1 <= a && a <= 399)
      color = 0;
    else if (400 <= a && a <= 799)
      color = 1;
    else if (800 <= a && a <= 1199)
      color = 2;
    else if (1200 <= a && a <= 1599)
      color = 3;
    else if (1600 <= a && a <= 1999)
      color = 4;
    else if (2000 <= a && a <= 2399)
      color = 5;
    else if (2400 <= a && a <= 2799)
      color = 6;
    else ifggV (2800 <= a && a <= 3199)
      color = 7;
    else if (3200 <= a)
      free++;
    v[color]++;
  }

  int ma = accum(v);
  int mi = 0;
  rep(i, 0, COLORS) mi += v[i];
  if (free == n)
    cout << 1 << " " << ma << endl;
  else
    cout << mi << " " << ma << endl;
  return 0;
}
