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