#include <bits/stdc++.h>
using namespace std;
using pii = pair<int, int>;
using vi = vector<int>;
using vb = vector<bool>;
using vvi = vector<vector<int>>;
using vlli = vector<long long int>;
using vpii = vector<pair<int, int>>;
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(0);
  cout.tie(0);
  int n, x, c = 0, ans = 0, maxRes, minRes;
  vector<bool> color(8, false);
  cin >> n;
  for (int i = 0; i < n; i++) {
    cin >> x;
    if (x <= 399)
      color[0] = true;
    else if (x <= 799)
      color[1] = true;
    else if (x <= 1199)
      color[2] = true;
    else if (x <= 1599)
      color[3] = true;
    else if (x <= 1999)
      color[4] = true;
    else if (x <= 2399)
      color[5] = true;
    else if (x <= 2799)
      color[6] = true;
    else if (x <= 3199)
      color[7] = true;
    else if (x >= 3200)
      c++;
  }
  for (int i = 0; i < 8; i++)
    if (color[i]) ans++;
  maxRes = ans + c;
  minRes = ans;
  cout << minRes << " " << maxRes;
}
