#include <bits/stdc++.h>
int main(void) {
  int n;
  int i;
  int a[10000];
  int c_1 = 1;
  int c_2 = 1;
  int c_3 = 1;
  int c_4 = 1;
  int c_5 = 1;
  int c_6 = 1;
  int c_7 = 1;
  int c_8 = 1;
  int sum = 0;
  int sum_ = 0;
  int min = 0;
  int max = 0;
  scanf("%d", &n);
  for (i = 0; i < n; i++) {
    scanf("%d", &a[i]);
  }
  for (i = 0; i < n; i++) {
    if (a[i] >= 1 && a[i] < 400 && c_1 == 1) {
      sum++;
      c_1 = 0;
    } else if (a[i] >= 400 && a[i] < 800 && c_2 == 1) {
      sum++;
      c_2 = 0;
    } else if (a[i] >= 800 && a[i] < 1200 && c_3 == 1) {
      sum++;
      c_3 = 0;
    } else if (a[i] >= 1200 && a[i] < 1600 && c_4 == 1) {
      sum++;
      c_4 = 0;
    } else if (a[i] >= 1600 && a[i] < 2000 && c_5 == 1) {
      sum++;
      c_5 = 0;
    } else if (a[i] >= 2000 && a[i] < 2400 && c_6 == 1) {
      sum++;
      c_6 = 0;
    } else if (a[i] >= 2400 && a[i] < 2800 && c_7 == 1) {
      sum++;
      c_7 = 0;
    } else if (a[i] >= 2800 && a[i] < 3200 && c_8 == 1) {
      sum++;
      c_8 = 0;
    } else if (a[i] >= 3200)
      sum_++;
  }
  min = sum;
  max = sum + sum_;
  printf("%d %d", min, max);
  return 0;
}
