#define _USE_MATH_DEFINES
#include <bits/stdc++.h>
using namespace std;

//template
#define rep(i,a,b) for(int i=(int)(a);i<(int)(b);i++)
#define ALL(v) (v).begin(),(v).end()
using ll=long long int;
const int inf = 0x3fffffff; const ll INF = 0x1fffffffffffffff; const double eps=1e-12;
template<typename T>inline bool chmax(T& a,T b){if(a<b){a=b;return 1;}return 0;}
template<typename T>inline bool chmin(T& a,T b){if(a>b){a=b;return 1;}return 0;}
//end

int C[5][5];
int nCr(int n,int r){
   if(C[0][0]==0){
      rep(i,0,5){
         C[i][0]=C[i][i]=1;
         rep(j,1,i){
            C[i][j]=(C[i-1][j-1]+C[i-1][j])%3;
         }
      }
   }
   int res=1;
   rep(_,0,30){
      res*=C[n%3][r%3];
      n/=3,r/=3;
   }
   return res;
}

int main(){
   int n;
   cin>>n;
   string s;
   cin>>s;

   int res=0;
   rep(i,0,n){
      if(s[i]=='R')continue;
      if(s[i]=='W')res=(res+nCr(n-1,i))%3;
      if(s[i]=='B')res=(res+nCr(n-1,i)*2)%3;
   }
   if(!(n&1))res=(3-res)%3;
   if(res==0)puts("R");
   if(res==1)puts("W");
   if(res==2)puts("B");
   return 0;
}
// give up
#include <bitset>
#include <cassert>
#include <iostream>
#include <iomanip>
#include <list>
#include <numeric>
#include <queue>
#include <unordered_map>
#include <unordered_set>
#include <valarray>

// alias, using declaration
using llint = long long; using ldouble = long double;
template <class T = llint> using vector = std::vector<T>;
template <class T = llint> using deque = std::deque<T>;
template <class T = llint> using list = std::list<T>;
template <class T = llint, class U = llint> using umap = std::unordered_map<T, U>;
template <class T = llint, class U = llint> using ummap = std::unordered_multimap<T, U>;
template <class T = llint> using uset = std::unordered_set<T>;
template <class T = llint> using umset = std::unordered_multiset<T>;
template <class T = llint, class U = T> using pair = std::pair<T, U>;
template <class T = llint> using varray = std::valarray<T>;
template <class T = llint, class U = vector<T>, class V = std::less<class U::value_type>> using pqueue = std::priority_queue<T, U, V>;
using std::array; using std::bitset; using std::string; using std::tuple;

// constant
constexpr llint INF = 0x7FFFFFFFFFFFFFFF;
constexpr llint INVALID = 0x8000000000000000;

namespace io {
  // in
  template <class... T, size_t... S> auto in(std::index_sequence<S...>) {tuple<T...> t; (..., (std::cin >> std::get<S>(t))); return t;}
  template <class... T, size_t... S> auto in(std::index_sequence<S...>, size_t n) {tuple<vector<T>...> t{vector<T>(n)...}; for (size_t i = 0; i < n; i++) (..., (std::cin >> std::get<S>(t)[i])); return t;}
  template <size_t N, class T = llint, class... U> auto in() {static_assert(N >= 1); if constexpr (N > 1) return in<N - 1, T, T, U...>(); else return in<T, U...>(std::index_sequence_for<T, U...>());}
  template <size_t N, class T = llint, class... U> auto in(size_t n) {static_assert(N >= 1); if constexpr (N > 1) return in<N - 1, T, T, U...>(n); else return in<T, U...>(std::index_sequence_for<T, U...>(), n);}
  template <size_t N, class T = llint> auto in(size_t n, size_t m) {static_assert(N == 1); vector<vector<T>> v(n, vector<T>(m)); for (auto&& vi : v) for (auto&& vij : vi) std::cin >> vij; return std::make_tuple(v);}
  // out
  template <class T, class... U> void out(const T& a, const U&... b) {std::cout << a << (sizeof...(b) ? " " : "\n"); if constexpr (sizeof...(b)) out(b...);}
  template <class T, class U = const char*> void out(const vector<T>& a, U d = " ") {for (auto&& b : a) std::cout << b << (&b != &a.back() ? d : "\n");}
}

int main() {
  // input
  auto [N, c] = io::in<1, llint, string>();

  // solve
  umap<char> c2n = {{'B', 0}, {'W', 1}, {'R', 2}};
  vector<> f(N), g(N);
  g[0] = 1;
  for (llint i = 1; i < N; i++) {
    g[i] = i;
  }
  for (llint i = 3; i < N; i *= 3) {
    for (llint j = i; j < N; j += i) {
      f[j]++;
      g[j] /= 3;
    }
  }
  for (llint i = 1; i < N; i++) {
    f[i] += f[i - 1];
    g[i] = (g[i - 1] * g[i]) % 3;
  }
  auto bc_mod3 = [&f, &g](llint n, llint r) {
    return f[n] - f[r] - f[n - r] > 0 ? 0 : (g[n] * g[r] * g[n - r]) % 3;
  };
  llint n_top = 0;
  for (llint i = 0; i < N; i++) {
    n_top += c2n[c[i]] * bc_mod3(N - 1, i);
  } 
  n_top %= 3;
  if (~N & 1) {
    n_top = (3 - n_top) % 3;
  }
  char result = array<char, 3>{'B', 'W', 'R'}[n_top];

  // output
  io::out(result);
}