#include <bits/stdc++.h>
using namespace std;
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  int n;
  scanf("%d", &n);
  int a = 0, b = 0, c = 0, d = 0, e = 0, f = 0, g = 0, h = 0, other = 0;
  for (int i = 0; i < n; i++) {
    int x;
    scanf("%d", &x);
    if (x >= 1 && x <= 399) a = 1;
    if (x >= 400 && x <= 799) b = 1;
    if (x >= 800 && x <= 1199) c = 1;
    if (x >= 1200 && x <= 1599) d = 1;
    if (x >= 1600 && x <= 1999) e = 1;
    if (x >= 2000 && x <= 2399) f = 1;
    if (x >= 2400 && x <= 2799) g = 1;
    if (x >= 2800 && x <= 3199) h = 1;
    if (x >= 3200) other++;
  }
  cout << a + b + c + d + e + f + g + h << " "
       << a + b + c + d + e + f + g + h + other << endl;
  return 0;
}
