#include <bits/stdc++.h>
using namespace std;
long long a[9];
signed main() {
  cin.tie(0);
  ios::sync_with_stdio(false);
  long long n;
  cin >> n;
  for (long long i = 0; i < n; i++) {
    long long c;
    cin >> c;
    a[min(8LL, c / 400)]++;
  }
  long long sum = 0;
  for (long long i = 0; i < 8; i++) {
    if (a[i]) sum++;
  }
  if (sum >= a[8])
    cout << sum << " " << min(8LL, sum + a[8]);
  else
    cout << max(8LL, a[8]) << " " << min(8LL, sum + a[8]);
  return 0;
}
