#include <iostream>

#define rep(i,n) for(int i=0;i<n;i++)
#define N 400000

using namespace std;

int a[400001], n, f[N+1], g[N+1], res;
char c;

int main(){
    cin >> n;
    rep(i,n){
        cin>> c;
        if(c=='W')a[i] = 0;
        else if(c=='B')a[i]=1;
        else a[i] = 2;
    }

    f[0] = 0;
    g[0] = 1;

    for(int i=1;i<=N;i++){
        int t = i;

        f[i] = f[i-1];
        while (t%3 == 0){
            f[i]++;
            t/=3;
        }
        g[i] = (g[i-1]*t)%3;
    }

    int r = n-1;

    rep(i,n){
        // rCi
        int t = f[r] - f[i] - f[r-i];
        // cout << i << " " << t << endl;
        if (t > 0)continue;
        // cout << i << " " << a[i] << " " << g[r] << " " << g[i] << " " << g[r-i] << endl;
        res = (res + a[i]*(g[r]*g[i]*g[r-i]))%3;
    }

    if(n%2 == 0){
        res = (3 - res)%3;
    }

    if(res == 0)cout << 'W' <<endl;
    else if (res == 1) cout << 'B' <<endl;
    else cout << 'R' << endl;
}
#include <bits/stdc++.h>
#define rep(i, n) for (int i = 0; i < (n); i++)
#define rep2(i, a, b) for (int i = (a); i < (b); ++i)
#define all(a) (a).begin(), (a).end()
using namespace std;
using ll = long long;
using P = pair<int, int>;

int main()
{
    int n;
    cin >> n;
    vector<int> x(n), y(n);
    rep(i, n) cin >> x[i] >> y[i];

    rep(i, n)
    {
        rep2(j, i + 1, n)
        {
            rep2(k, j + 1, n)
            {
                int dx = (x[j] - x[i]), dy = (y[j] - y[i]);
                int ddx = (x[k] - x[i]), ddy = (y[k] - y[i]);
                if ((dx * ddy) == (dy * ddx))
                {
                    cout << "Yes" << '\n';
                    return 0;
                }
            }
        }
    }
    cout << "No" << '\n';
    return 0;
}
