Language: C++

g#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 = colors == 0 ? 1 : colors;
  eprintf("col,zero,free:%d,%d,%d\n", colors,zero,free);

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

  return 0;
}


Compiler output:
a.cc:1:2: error: stray '#' in program
    1 | g#include <bits/stdc++.h>
      |  ^
a.cc:1:1: error: 'g' does not name a type
    1 | g#include <bits/stdc++.h>
      | ^
a.cc: In function 'int main()':
a.cc:22:3: error: 'cin' was not declared in this scope
   22 |   cin >> n;
      |   ^~~
a.cc:23:3: error: 'vector' was not declared in this scope
   23 |   vector<int> v(9, 0);
      |   ^~~~~~
a.cc:23:10: error: expected primary-expression before 'int'
   23 |   vector<int> v(9, 0);
      |          ^~~
a.cc:27:18: error: 'v' was not declared in this scope
   27 |     if(a <= 399) v[0]++;
      |                  ^
a.cc:28:23: error: 'v' was not declared in this scope
   28 |     else if(a <= 799) v[1]++;
      |                       ^
a.cc:29:24: error: 'v' was not declared in this scope
   29 |     else if(a <= 1199) v[2]++;
      |                        ^
a.cc:30:24: error: 'v' was not declared in this scope
   30 |     else if(a <= 1599) v[3]++;
      |                        ^
a.cc:31:24: error: 'v' was not declared in this scope
   31 |     else if(a <= 1999) v[4]++;
      |                        ^
a.cc:32:24: error: 'v' was not declared in this scope
   32 |     else if(a <= 2399) v[5]++;
      |                        ^
a.cc:33:24: error: 'v' was not declared in this scope
   33 |     else if(a <= 2799) v[6]++;
      |                        ^
a.cc:34:24: error: 'v' was not declared in this scope
   34 |     else if(a <= 3199) v[7]++;
      |                        ^
a.cc:35:10: error: 'v' was not declared in this scope
   35 |     else v[8]++;
      |          ^
a.cc:40:10: error: 'v' was not declared in this scope
   40 |   REP(i, v.size()-1) {
      |          ^
a.cc:3:44: note: in definition of macro 'REP'
    3 | #define REP(i, n) for(int i = 0; i < (int)(n); ++i)
      |                                            ^
a.cc:44:14: error: 'v' was not declared in this scope
   44 |   int free = v[8];
      |              ^
a.cc:45:23: error: 'min' was not declared in this scope; did you mean 'main'?
   45 |   int maxc = colors + min(zero, free);
      |                       ^~~
      |                       main
a.cc:49:3: error: 'printf' was not declared in this scope
   49 |   printf("%d %d\n", minc, maxc);
      |   ^~~~~~
a.cc:1:1: note: 'printf' is defined in header '<cstdio>'; this is probably fixable by adding '#include <cstdio>'
  +++ |+#include <cstdio>
    1 | g#include <bits/stdc++.h>