//Littleboy123 Template 1.8
#include <bits/stdc++.h>
#include <ext/pb_ds/assoc_container.hpp>
#include <ext/pb_ds/tree_policy.hpp>
using namespace __gnu_pbds;
using namespace std;

//pragmas

// #pragma comment(linker, "/stack:200000000")
// #pragma GCC target("sse,sse2,sse3,ssse3,sse4,popcnt,abm,mmx,avx,tune=native")
// #pragma GCC target ("avx2")
// #pragma GCC optimization ("O3")
// #pragma GCC optimization ("unroll-loops")


typedef pair<int, int> ii;
typedef vector<int> vi;
typedef vector<ii> vii;
typedef long long int ll;
typedef pair<ll, ll> pll;
typedef unsigned long long int ull;
typedef long double ld;
typedef unsigned long long ull;

const long double pi = acos(-1.0);

#define FOR(a,b,c) for(int (a)=(b);(a)<(c);++(a))
#define FORE(a,b,c) for(int (a)=(b);(a)<=(c);++(a))
#define FORN(a,b,c) for(int (a)=(b);(a)>(c);--(a))
#define FORNE(a,b,c) for(int (a)=(b);(a)>=(c);--(a))
#define TC(n) cout << "Case #" << (n) << ": "
#define DEBUG(x) cout << "DEBUG " << #x << ' ' << x << '\n';
#define MEM(a,b) memset((a), (b), sizeof((a)))
#define MAX(a,b) (a) = max((a), (b))
#define MIN(a,b) (a) = min((a), (b))
#define nl '\n'
#define fi first
#define se second
#define mp make_pair
#define pb push_back
#define eb emplace_back
#define ordered_set tree<ll, null_type,less_equal<ll>, rb_tree_tag,tree_order_statistics_node_update>

void init(){
    ios_base::sync_with_stdio(false);
    cin.tie(NULL);
    cout.tie(NULL);
}

void infile(){
    freopen("dull.in", "r", stdin);
}

void outfile(){
    freopen("input.txt", "w", stdout);
}

ll rp(ll a, ll b, ll mod){
    ll res = 0;
    while(b > 0){
        if(b & 1)
            res = (res + a) % mod;
        res %= mod;
        a = (a << 1)%mod;
        b = b >> 1;
    }
    return res;
}

ll modex(ll a, ll b, ll mod){
    if(b == 0)
        return 1;
    if(b == 1)
        return a;
    ll tmp = modex(a, b/2LL, mod);
    tmp = rp(tmp, tmp, mod);
    if(b & 1LL)
        tmp = rp(tmp, a, mod);
    return tmp;
}

ll ex(ll a, ll b){
    if(b == 0)
        return 1;
    if(b == 1)
        return a;
    ll tmp = ex(a, b/2LL);
    tmp = (tmp * tmp);
    if(b & 1LL)
        tmp = (tmp * a);
    return tmp;
}

//End of template

int main(){
    init();

    ll n, x;
    string s;
    cin >> n >> x >> s;
    FOR(i, 0, n){
        if(s[i] == 'x'){
            x = max(x-1, 0LL);
        }
        else{
            x++;
        }
    }
    cout << x << endl;
    return 0;
}

#include <bits/stdc++.h>

#define fst(t) std::get<0>(t)
#define snd(t) std::get<1>(t)
#define thd(t) std::get<2>(t)
#define unless(p) if(!(p))
#define until(p) while(!(p))

#ifdef LOCAL
#define log(val) std::cerr << std::setw(3) << __LINE__ << "| " << #val << " = " << (val) << std::endl
#define dbg(proc) proc
#else
#define log(val) 0
#define dbg(proc) 0
#endif

template <typename T>
std::ostream& operator<<(std::ostream& os,const std::vector<T>& v){os << "{";if(!v.empty()){os << v[0];for(std::size_t i=1;i<v.size();++i){os << ", " << v[i];}}return os << "}";}

using ll = std::int64_t;
using P = std::tuple<int,int>;

template <typename T>
std::tuple<T, T, T> extgcd(T a, T b){
    T s1 = 1, t1 = 0, s2 = 0, t2 = 1;
    while(b != 0){
        std::tie(s1, t1, s2, t2) = std::make_tuple(s2, t2, s1 - (a / b) * s2, t1 - (a / b) * t2);
        std::tie(a, b) = std::make_tuple(b, a % b);
    }
    return std::make_tuple(s1, t1, a);
}

// 注意: a と mod が互いに素である必要がある
template <typename T>
T mod_inverse(T a, T mod){
    T b;
    std::tie(b, std::ignore, std::ignore) = extgcd(a, mod);
    if(b < 0){b += mod;}
    return b;
}

template <typename T>
struct Combinatorics{
    std::vector<T> fact, inv_fact, pow;

    Combinatorics(T max) : fact(max + 1), inv_fact(max + 1), pow(max + 1) {
        fact[0] = 1;
        pow[0] = 0;
        for(T i=1;i<=max;++i){
            int j = i, p = 0;
            while(j % 3 == 0){
                j /= 3;
                p += 1;
            }
            
            fact[i] = j * fact[i - 1] % 3;
            pow[i] = p + pow[i-1];
        }

        for(T i=0;i<=max;++i){
            inv_fact[i] = mod_inverse(fact[i], 3);
        }
    }

    T nCk(T n, T k){
        if(n < k){return 0;}
        if(pow[n] > pow[n-k] + pow[k]){
            return 0;
        }
        return fact[n] * inv_fact[k] % 3 * inv_fact[n - k] % 3;
    }
};

Combinatorics<int> comb(400100);
int N;
std::string S;
int A[400100];
std::string T = "BWR";

int main(){
    std::cin.tie(nullptr);
    std::ios::sync_with_stdio(false);
    
    std::cin >> N >> S;

    for(int i=0;i<N;++i){
        if(S[i] == 'B'){
            A[i] = 0;
        }else if(S[i] == 'W'){
            A[i] = 1;
        }else{
            A[i] = 2;
        }
    }

    int res = 0;

    for(int i=0;i<N;++i){
        // std::cout << A[i] << ", " << comb.nCk(N - 1, i) << std::endl;
        res += A[i] * comb.nCk(N - 1, i);
    }

    res %= 3;

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

    std::cout << T[res] << std::endl;
}
