#include <bits/stdc++.h>
using namespace std;
const int inf = 999999999;
const int mod = 1000000007;
inline int Getint() {
  char ch = getchar();
  while (ch < '0' || ch > '9') ch = getchar();
  int ret = 0;
  while (ch >= '0' && ch <= '9') ret = ret * 10 + ch - '0', ch = getchar();
  return ret;
}
char ch[210];
int n;
inline void Work() {
  int cntb = 0, cntg = 0, cntr = 0;
  for (int i = 1; i <= n; i++) {
    if (ch[i] == 'B') cntb++;
    if (ch[i] == 'G') cntg++;
    if (ch[i] == 'R') cntr++;
  }
  if (cntb && cntg && cntr) {
    puts("BGR");
    return;
  }
  if (cntb == n) {
    puts("B");
    return;
  }
  if (cntg == n) {
    puts("G");
    return;
  }
  if (cntr == n) {
    puts("R");
    return;
  }
  if (cntb == 1) {
    if (cntg) {
      if (cntg == 1)
        puts("R");
      else
        puts("BR");
    } else {
      if (cntr == 1)
        puts("G");
      else
        puts("BG");
    }
  } else if (cntg == 1) {
    if (cntb) {
      if (cntb == 1)
        puts("R");
      else
        puts("GR");
    } else {
      if (cntr == 1)
        puts("B");
      else
        puts("BG");
    }
  } else if (cntr == 1) {
    if (cntb) {
      if (cntb == 1)
        puts("G");
      else
        puts("GR");
    } else {
      if (cntg == 1)
        puts("B");
      else
        puts("BR");
    }
  } else {
    puts("BGR");
  }
}
int main() {
  n = Getint();
  scanf("%s", ch + 1);
  Work();
  return 0;
}
