#include <bits/stdc++.h>

#define REP(i, n) for(int i = 0; i < (int)(n); ++i)
#define FOR(i, m, n) for(int i = (m); i < (int)(n); ++i)
#define ALL(x) (x).begin(), (x).end()
#define INF 2000000000

#ifdef LOCAL
  #define eprintf(...) fprintf(stdout, __VA_ARGS__)
#else
  #define eprintf(...) 0
#endif

using namespace std;

typedef long long LL;
typedef unsigned long long ULL;
typedef unsigned int uint;

int main() {
  int n;
  cin >> n;
  vector<int> v(9, 0);
  int a;
  REP(i, n) {
    cin >> a;
    if(a <= 399) v[0]++;
    else if(a <= 799) v[1]++;
    else if(a <= 1199) v[2]++;
    else if(a <= 1599) v[3]++;
    else if(a <= 1999) v[4]++;
    else if(a <= 2399) v[5]++;
    else if(a <= 2799) v[6]++;
    else if(a <= 3199) v[7]++;
    else v[8]++;
  }

  int colors = 0;
  int zero = 0;
  REP(i, v.size()-1) {
    if(v[i] > 0) colors++;
    else zero++;
  }
  int free = v[8];
  int maxc = colors + min(zero, free);
  int minc = max(colors, free);
  eprintf("col,zero,free:%d,%d,%d\n", colors,zero,free);

  printf("%d %d\n", minc, maxc);

  return 0;
}
