#include <bits/stdc++.h>
using namespace std;
const int INF = 1e9;
const long long MOD = 1e9 + 7;
int N;
int a, b, c, d, e, f, g, h, cnt;
int main() {
  cin >> N;
  for (int i = 0; i < N; i++) {
    int x;
    scanf("%d", &x);
    if (1 <= x && x < 400) a = 1;
    if (400 <= x && x < 800) b = 1;
    if (800 <= x && x < 1200) c = 1;
    if (1200 <= x && x < 1600) d = 1;
    if (1600 <= x && x < 2000) e = 1;
    if (2000 <= x && x < 2400) f = 1;
    if (2400 <= x && x < 2800) g = 1;
    if (2800 <= x && x < 3200) h = 1;
    if (x >= 3200) cnt++;
  }
  int Min = max(a + b + c + d + e + f + g + h, 0);
  int Max = Min + cnt;
  cout << Min << " " << Max << endl;
}
