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

int main()
{
    ios::sync_with_stdio(false);
    cin.tie(nullptr);
    int N,M;
    cin>>N>>M;
    string S;
    cin>>S;
    stack<char>AC,WA;
    for(char& c:S)
    {
        if(c=='W')WA.push(c);
        else if(c=='A')
        {
            if(M==0)
            {
                if(WA.empty())
                {
                    cout<<"No"<<endl;
                    return 0;
                }
                WA.pop();
            }
            else
            {
                M--;
                AC.push(c);
            }
        }
        else
        {
            if(AC.empty())
            {
                cout<<"No"<<endl;
                return 0;
            }
            AC.pop();
        }
    }
    cout<<"Yes"<<endl;
}