#include <bits/stdc++.h>
using Set = std::unordered_set<uint32_t>;
void FindAndUpdate(int key, Set* o) {
  auto find = o->find(key);
  if (find == o->end()) {
    o->insert(key);
  }
}
int main() {
  uint32_t n = 0;
  scanf("%d", &n);
  uint32_t a = 0;
  uint32_t i = 0;
  Set o;
  uint32_t free = 0;
  while (std::cin >> a) {
    if (a >= 1 && a <= 399) {
      FindAndUpdate(1, &o);
    } else if (a >= 400 && a <= 799) {
      FindAndUpdate(2, &o);
    } else if (a >= 800 && a <= 1199) {
      FindAndUpdate(3, &o);
    } else if (a >= 1200 && a <= 1599) {
      FindAndUpdate(4, &o);
    } else if (a >= 1600 && a <= 1999) {
      FindAndUpdate(5, &o);
    } else if (a >= 2000 && a <= 2399) {
      FindAndUpdate(6, &o);
    } else if (a >= 2400 && a <= 2799) {
      FindAndUpdate(7, &o);
    } else if (a >= 2800 && a <= 3199) {
      FindAndUpdate(8, &o);
    } else {
      free++;
    }
    i++;
    if (i >= n) {
      break;
    }
  }
  uint32_t max = std::min(uint32_t(o.size()) + free, uint32_t(8));
  uint32_t min = std::max(uint32_t(o.size()), uint32_t(1));
  std::cout << min << " " << max << std::endl;
}
