#include <bits/stdc++.h>
using namespace std;
const int MAX = (int)(4800 + 5);
int n;
int board[MAX];
int ans, ans_;
int main(void) {
  scanf("%d", &n);
  for (int i = 0; i < n; ++i) {
    int a;
    scanf("%d", &a);
    board[a] += 1;
  }
  bool range[8 + 5];
  int overrange = 0;
  for (int i = 0; i < 8 + 5; ++i) {
    range[i] = false;
  }
  for (int i = 1; i <= 4800; ++i) {
    if (1 <= i && i < 400) {
      range[0] |= (board[i] > 0) ? true : false;
    } else if (400 <= i && i < 800) {
      range[1] |= (board[i] > 0) ? true : false;
    } else if (800 <= i && i < 1200) {
      range[2] |= (board[i] > 0) ? true : false;
    } else if (1200 <= i && i < 1600) {
      range[3] |= (board[i] > 0) ? true : false;
    } else if (1600 <= i && i < 2000) {
      range[4] |= (board[i] > 0) ? true : false;
    } else if (2000 <= i && i < 2400) {
      range[5] |= (board[i] > 0) ? true : false;
    } else if (2400 <= i && i < 2800) {
      range[6] |= (board[i] > 0) ? true : false;
    } else if (2800 <= i && i < 3200) {
      range[7] |= (board[i] > 0) ? true : false;
    } else if (3200 <= i) {
      overrange += board[i];
    }
  }
  int cnt = 0;
  for (int i = 0; i < 8; ++i) {
    if (range[i]) cnt += 1;
  }
  if (cnt == 0) {
    ans = 1;
    ans_ = overrange;
  } else {
    ans = cnt;
    ans_ = (ans + overrange > 8) ? 8 : ans + overrange;
  }
  printf("%d %d\n", ans, ans_);
  return 0;
}
