#include <bits/stdc++.h>
using namespace std;
int main() {
  int N;
  cin >> N;
  vector<bool> b(10, false);
  int a, free = 0;
  for (int i = 0; i < N; i++) {
    cin >> a;
    if (1 <= a && a < 400) b[0] = true;
    if (400 <= a && a < 800) b[1] = true;
    if (800 <= a && a < 1200) b[2] = true;
    if (1200 <= a && a < 1600) b[3] = true;
    if (1600 <= a && a < 2000) b[4] = true;
    if (2000 <= a && a < 2400) b[5] = true;
    if (2400 <= a && a < 2800) b[6] = true;
    if (2800 <= a && a < 3200) b[7] = true;
    if (3200 <= a) free++;
  }
  int B = 0;
  for (int i = 0; i <= 7; i++)
    if (b[i]) B++;
  cout << max(B, 1) << " " << min(8, B + free) << endl;
  return 0;
}
