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