#include <bits/stdc++.h>
using namespace std;
inline string uppercase(string s) {
  int n = (int)s.size();
  for (int i = 0; i < n; i++)
    if (s[i] >= 'a' && s[i] <= 'z') s[i] = s[i] - 'a' + 'A';
  return s;
}
inline string lowercase(string s) {
  int n = (int)s.size();
  for (int i = 0; i < n; i++)
    if (s[i] >= 'A' && s[i] <= 'Z') s[i] = s[i] - 'A' + 'a';
  return s;
}
int main() {
  int n, ans = 0;
  cin >> n;
  vector<int> v(n), a(8);
  int ex = 0;
  for (int i = 0; i < n; i++) {
    cin >> v[i];
    if (v[i] >= 1 && v[i] < 400) a[0]++;
    if (v[i] >= 400 && v[i] < 800) a[1]++;
    if (v[i] >= 800 && v[i] < 1200) a[2]++;
    if (v[i] >= 1200 && v[i] < 1600) a[3]++;
    if (v[i] >= 1600 && v[i] < 2000) a[4]++;
    if (v[i] >= 2000 && v[i] < 2400) a[5]++;
    if (v[i] >= 2400 && v[i] < 2700) a[6]++;
    if (v[i] >= 2800 && v[i] < 3200) a[7]++;
    if (v[i] >= 3200) ex++;
  }
  for (int i = 0; i < 8; i++) {
    if (a[i] != 0) ans++;
  }
  cout << ans << " " << ans + ex << endl;
  return 0;
}
