#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, ans = 0, p = 0;
  cin >> n;
  int a[n];
  bool o = 1, b = 1, c = 1, d = 1, e = 1, f = 1, g = 1, h = 1;
  for (int i = 0; i < n; i++) {
    cin >> a[i];
    if (1 <= a[i] && a[i] <= 399 && o) ans++, o = 0;
    if (400 <= a[i] && a[i] <= 799 && b) ans++, b = 0;
    if (800 <= a[i] && a[i] <= 1199 && c) ans++, c = 0;
    if (1200 <= a[i] && a[i] <= 1599 && d) ans++, d = 0;
    if (1600 <= a[i] && a[i] <= 1999 && e) ans++, e = 0;
    if (2000 <= a[i] && a[i] <= 2399 && f) ans++, f = 0;
    if (2400 <= a[i] && a[i] <= 2799 && g) ans++, g = 0;
    if (2800 <= a[i] && a[i] <= 3199 && h) ans++, h = 0;
    if (a[i] >= 3200) p++;
  }
  cout << ans << " " << ans + p << endl;
  return 0;
}
