#include <bits/stdc++.h>
using namespace std;
int main() {
  int n;
  cin >> n;
  string s;
  cin >> s;
  int ct = 0, i, j;
  map<char, int> mp1;
  int len = s.length();
  int bc, rc, gc;
  gc = rc = bc = 0;
  for (i = 0; i < len; i++) {
    if (s[i] == 'R') rc++;
    if (s[i] == 'G') gc++;
    if (s[i] == 'B') bc++;
  }
  if (gc > 0 && bc > 0 && rc > 0)
    printf("BGR\n");
  else if (gc == 0) {
    if (rc == 0)
      printf("B");
    else if (bc == 0)
      printf("R");
    else if (rc == 1 && bc == 1)
      printf("G");
    else if (rc > 1 && bc == 1)
      printf("BG");
    else if (bc > 1 && rc == 1)
      printf("GR");
    else
      printf("BGR");
  } else if (bc == 0) {
    if (gc == 0)
      printf("R");
    else if (rc == 0)
      printf("G");
    else if (gc == 1 && rc == 1)
      printf("B");
    else if (rc > 1 && gc == 1)
      printf("BG");
    else if (gc > 1 && rc == 1)
      printf("BR");
    else
      printf("BGR");
  } else if (rc == 0) {
    if (gc == 0)
      printf("B");
    else if (bc == 0)
      printf("G");
    else if (gc == 1 && bc == 1)
      printf("R");
    else if (bc > 1 && gc == 1)
      printf("GR");
    else if (gc > 1 && bc == 1)
      printf("BR");
    else
      printf("BGR");
  }
  return 0;
}
