#include <bits/stdc++.h>
using namespace std;
const long long MOD = 1000000007;
int min(int a, int b) {
  if (a > b) return b;
  return a;
}
int max(int a, int b) {
  if (a < b) return b;
  return a;
}
int cut(int a, int b) { return (a - a % b) / b; }
int n;
int a, r;
bool ch[8] = {false};
int counter = 0;
int ansmin = 0;
int main() {
  cin >> n;
  for (int i = 0; i < n; i++) {
    cin >> a;
    r = cut(a, 400);
    if (r >= 8) {
      counter++;
      continue;
    }
    ch[r] = true;
  }
  for (int i = 0; i < 8; i++) {
    if (ch[i]) ansmin++;
  }
  cout << max(ansmin, 1) << " " << min(8, ansmin + counter) << endl;
  return 0;
}
