#include <bits/stdc++.h>
using namespace std;
signed main() {
  long long N;
  cin >> N;
  bitset<8> A;
  long long count = 0;
  for (long long i = (long long)(0); i < (long long)(N); i++) {
    long long X;
    cin >> X;
    X /= 400;
    if (8 <= X)
      count++;
    else
      A.set(X);
  }
  long long ans1 = A.count(), ans2;
  ans2 = ans1 + count;
  if (ans2 >= 9) ans2 = 8;
  cout << ans1 << " " << ans2 << endl;
}
