#include<bits/stdc++.h>
using namespace std;
typedef long long ll;
#define forn(i, n) for(ll i = 0;i<n;i++)
#define for1(i, n) for(ll i = 1;i<=n;i++)
const ll N  = 1e5 + 10;
char s[N];
ll n,K;
void input(){
   cin >> n >> K;
   scanf("%s", s + 1);
}
ll dis(ll x,ll y){
   return labs(x - y);
}
char ans[N];
void solve(){
   ll sum = 0;
   ll trace = 0;
   for1(i, n){
       ll val = s[i] - 'a';

       ll cand = 0;
       if(val<=12) cand = 25;
       else cand = 0;

       if(dis(val, cand) + sum <K){
          ans[i] = cand + 'a';
          sum+= dis(val, cand);
       }
       else{
         for(ll j = 0;j<=25;j++){
            ll d = dis(j, val);
            if(d + sum == K){
                ans[i] = j + 'a';
                sum = K;
                trace = i;
                break;
            }
         }
       }
       if(sum == K) break;
   }
   if(sum < K) {
    cout<< -1 << endl;
    return;
   }
   for1(i, trace) printf("%c", ans[i]);
   for(ll i = trace + 1;i<=n;i++) printf("%c", s[i]);
}
int main(){
   // freopen("c.c","r",stdin);
   input();
   solve();
}


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

int dis(int a, int b){
    return abs(a-b);
}
int main()
{
    char s[100005];
    char ans[10005];
    int n,k;
    char line[1000];
    sscanf(gets(line),"%d%d",&n,&k);
    gets(s);
    if(k==0){  printf("%s", s);return 0;}

    int sum = 0;
    int maxcur=0;
    int en =0;

    for(int i = 0;i<n;i++){
        int nb = s[i] -'a';
        int maxcur = max(25-nb, nb);

        if((sum+ maxcur)<=k){

            if(nb<=12) ans[i] = 'z';
            else        ans[i] = 'a';
                         en = i;
                         sum = sum + maxcur;
        }
        else{
            for(int j = 0;j<26;j++)
            {
                if((dis(j,nb) + sum)==k){
                        en = i;
                    ans[i] = j + 'a';
                    sum = k;
                    break;
                }
            }
        break;///them 1 lan break nua cho chac
        }
    }
    if(en<n)
       for(int i = en+1;i<n;i++) ans[i] = s[i];
    if(sum==k) {
    for(int i = 0;i<n;i++) printf("%c",ans[i]);
    }
    else printf("-1");

}


#include<bits/stdc++.h>
using namespace std;
#define          mp                make_pair
#define          pb                push_back
typedef long long int big;
#define         x                  first
#define         y                  second
#define         forn(i, n)         for(int i = 0;i<n;i++)
#define         nfor(i, n)         for(int i = n-1;i>=0;i--)
typedef pair<int, int>             ii;
const int N = 1000000;
char a[N];
int n,k;
int dis(int a, int b){ return abs(a-b); }
void input(){
    char line[100];
    sscanf(gets(line),"%d %d",&n,&k);
    scanf("%s",a);
}
void solve(){
    int sum = 0;
    char b[N];
    int trace = 0;
    for(int i = 0;i<n;i++){
        int it = a[i] - 'a';
        int res = max( it, 25 - it);
        sum+=res;
        if(sum<k){
            if(it<=13) b[i] = 'z';
            else       b[i] = 'a';
            trace = i + 1;
        }
        else{
            sum -=res;
            for(int j = 0;j<26;j++){
                int chec = dis(j, it);
                if(chec + sum == k){
                    b[i] = 'a' + j;
                    sum = k;
                    trace = i+1;
                    break;
                }
            }
            break;
        }
    }
    if(sum<k){ printf("-1");return;}
    for(int i = trace;i<n;i++) b[i] = a[i];
    printf("%s",b);
}
int main(){
    input();
    solve();
}


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

int dis(int a, int b){
    return abs(a-b);
}
int main()
{
    char s[100005];
    char ans[10005];
    int n,k;
    char line[1000];
    sscanf(gets(line),"%d %d",&n,&k);
    scanf("%s",s);
    if(k==0){  printf("%d", s);return 0;}

    int sum = 0;
    int maxcur=0;
    int en =0;

    for(int i = 0;i<n;i++){
        int nb = s[i] -'a';
        int maxcur = max(25-nb, nb);

        if((sum+ maxcur)<=k){

            if(nb<=12) ans[i] = 'z';
            else        ans[i] = 'a';
                         en = i;
                         sum = sum + maxcur;
        }
        else{
            for(int j = 0;j<26;j++)
            {
                if((dis(j,nb) + sum)==k){
                        en = i;
                    ans[i] = j + 'a';
                    sum = k;
                    break;
                }
            }
        break;///them 1 lan break nua cho chac
        }
    }
    if(en<n)
       for(int i = en+1;i<n;i++) ans[i] = s[i];
    if(sum==k) {
        for(int i = 0;i<n;i++) printf("%c",ans[i]);
    }
    else printf("-1");
    return 0;

}


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

int dis(int a, int b){
    return abs(a-b);
}
int main()
{
    char s[200005];
    char ans[20005];
    int n,k;
    char line[1000];
    sscanf(gets(line),"%d%d",&n,&k);
    gets(s);
    if(k==0){  printf("%d", s);return 0;}

    int sum = 0;
    int maxcur=0;
    int en =0;

    for(int i = 0;i<n;i++){
        int nb = s[i] -'a';
        int maxcur = max(25-nb, nb);

        if((sum+ maxcur)<k){

            if(nb<=12) ans[i] = 'z';
            else         ans[i] = 'a';
                         en = i;
                         sum = sum + maxcur;
        }
        else{
            for(int j = 0;j<26;j++)
            {
                if((dis(j,nb) + sum)==k){ en = i;
                    ans[i] = j + 'a';
                    sum = k;
                    break;
                }
            }
        }
    }
    for(int i = en+1;i<n;i++) ans[i] = s[i];
    if(sum==k) {
    for(int i = 0;i<n;i++) printf("%c",ans[i]);
    }
    else printf("-1");

}


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

int dis(int a, int b){
    return abs(a-b);
}
int main()
{
    char s[100005];
    char ans[10005];
    int n,k;
    char line[100];
    sscanf(gets(line),"%d %d",&n,&k);
    gets(s);
    if(k==0){  printf("%d\n", s);return 0;}
    int sum = 0;
    int maxcur=0;
    int en =0;

    for(int i = 0;i<n;i++){

        int nb = s[i] -'a';
        int maxcur = max(25-nb, nb);

        if((sum+ maxcur)<k){

            if(nb<=12) ans[i] = 'z';
            else         ans[i] = 'a';
                         en = i;
                         sum = sum + maxcur;
        }
        else{
            for(int j = 0;j<26;j++)
            {
                if((dis(j,nb)+sum)==k){ en = i;
                    ans[i] = j+'a';
                    sum = k;
                    break;
                }
            }
        }
    }
    for(int i = en+1;i<n;i++) ans[i] = s[i];
    if(sum==k) {
    printf("%s",ans);
    printf("\n");
    }
    else cout<<"-1"<<endl;

}


#include<iostream>
#include<cstdio>
#include<set>
using namespace std;
int main(){
	std::ios::sync_with_stdio(0);
int n,k;
cin>>n>>k;
char s;
int arr[100001];
for(int i=0;i<n;i++){
    cin>>s;
   arr[i]=int(s);
}
int mn;
for(int i=0;i<n&&k;i++){
	if(122-arr[i]>=arr[i]-97&&(arr[i]+(122-arr[i])<=122||arr[i]+k<=122)){
		mn=min(122-arr[i],k);
		k-=mn;
		arr[i]+=mn;
	}
	else if(arr[i]-(arr[i]-79)>=97||arr[i]-k>=97){
	arr[i]-=min(arr[i]-97,k);
		k-=min(arr[i]-97,k);
	}

}
if(k)
    cout<<"-1\n";
else
    for(int i=0;i<n;i++)
    cout<<char(arr[i]);
cout<<endl;
return 0;
}


#include<iostream>
#include<cstdio>
#include<set>
using namespace std;
int main(){
int n,k;
scanf("%d%d",&n,&k);
char s;
int arr[100001];
getchar();
for(int i=0;i<n;i++){
    scanf("%c",&s);
   arr[i]=int(s);
}
for(int i=0;i<n&&k;i++){
	if(122-arr[i]>=arr[i]-97){
		arr[i]+=min(122-arr[i],k);
		k-=min(122-arr[i],k);
	}
	else{
	arr[i]-=min(arr[i]-97,k);
		k-=min(arr[i]-97,k);
	}

}
if(k)
    printf("-1\n");
else
    for(int i=0;i<n;i++)
    printf("%c",char(arr[i]));
printf("\n");
system("pause");
return 0;
}


#include<iostream>
#include<cstdio>
#include<set>
using namespace std;
int main(){
int n,k;
scanf("%d%d",&n,&k);
char s;
int arr[100001];
getchar();
for(int i=0;i<n;i++){
    scanf("%c",&s);
   arr[i]=int(s);
}
for(int i=0;i<n&&k;i++){
	if(122-arr[i]>=arr[i]-97){
		arr[i]+=min(122-arr[i],k);
		k-=min(122-arr[i],k);
	}
	else{
	arr[i]-=min(arr[i]-97,k);
		k-=min(arr[i]-97,k);
	}

}
if(k)
    printf("-1\n");
else
    for(int i=0;i<n;i++)
    printf("%c",char(arr[i]));
printf("\n");
return 0;
}


#include<iostream>
#include<cstdio>
#include<set>
using namespace std;
int main(){
	std::ios::sync_with_stdio(0);
int n,k;
cin>>n>>k;
char s;
int arr[100001];
for(int i=0;i<n;i++){
    cin>>s;
   arr[i]=int(s);
}
int mn;
for(int i=0;i<n&&k;i++){
	if(122-arr[i]>=arr[i]-97&&(arr[i]+(122-arr[i])<=122||arr[i]+k<=122)){
		mn=min(122-arr[i],k);
		k-=mn;
		arr[i]+=mn;
	}
	else if(arr[i]-(arr[i]-97)>=97||arr[i]-k>=97){
	mn=min(arr[i]-97,k);
	arr[i]-=mn;
		k-=mn;
	}
}
if(k)
    cout<<"-1\n";
else
    for(int i=0;i<n;i++)
    cout<<char(arr[i]);
cout<<endl;
return 0;
}


#include<iostream>
#include<cstdio>
#include<set>
using namespace std;
int main(){
int n,k;
scanf("%d%d",&n,&k);
char s;
int arr[100001];
multiset<pair<int,int>>st;
getchar();
for(int i=0;i<n;i++){
    scanf("%c",&s);
	st.insert(make_pair(int(s),i));
   arr[i]=int(s);
}
multiset<pair<int,int>>::iterator it;
if(122-(st.begin()->first)>=(st.begin()->first)-97){
    for(it=st.begin();it!=st.end()&&k;it++){
        arr[it->second]=it->first+min(k,122-it->first);
        k-=min(k,122-it->first);
    }
}
else{
    for(it=st.begin();it!=st.end()&&k;it++){
        arr[it->second]=it->first+min(k,it->first-97);
        k-=min(k,it->first-97);
    }
}
if(k)
    printf("-1\n");
else
    for(int i=0;i<n;i++)
    printf("%c",char(arr[i]));
printf("\n");
return 0;
}


#include<iostream>
#include<cstdio>
#include<set>
using namespace std;
int main(){
int n,k;
scanf("%d%d",&n,&k);
char s;
int arr[100001];
getchar();
for(int i=0;i<n;i++){
    scanf("%c",&s);
   arr[i]=int(s);
}
for(int i=0;i<n&&k;i++){
	if(122-arr[i]>=arr[i]-97){
		arr[i]+=min(122-arr[i],k);
		k-=min(122-arr[i],k);
	}
	else{
	arr[i]+=min(arr[i]-97,k);
		k-=min(arr[i]-97,k);
	}

}
if(k)
    printf("-1\n");
else
    for(int i=0;i<n;i++)
    printf("%c",char(arr[i]));
printf("\n");
return 0;
}


#include<iostream>
#include<cstdio>
#include<map>
using namespace std;
int main(){
int n,k;
scanf("%d%d",&n,&k);
char s;
int arr[100001];
map<int,int>mp;
getchar();
for(int i=0;i<n;i++){
    scanf("%c",&s);
    mp[int(s)]=i;
   arr[i]=int(s);
}
map<int,int>::iterator it;
if(122-(mp.begin()->first)>=(mp.begin()->first)-97){
    for(it=mp.begin();it!=mp.end()&&k;it++){
        arr[it->second]=it->first+min(k,122-it->first);
        k-=min(k,122-it->first);
    }
}
else{
    for(it=mp.begin();it!=mp.end()&&k;it++){
        arr[it->second]=it->first+min(k,it->first-97);
        k-=min(k,it->first-97);
    }
}
if(k)
    printf("-1\n");
else
    for(int i=0;i<n;i++)
    printf("%c",char(arr[i]));
printf("\n");

return 0;
}


#include <iostream>
#include <fstream>
#include <algorithm>
#include <string>
#include <vector>
#include <stdio.h>
using namespace std;

int main(){
    vector<char> alph = {'a', 'b', 'c', 'd', 'e', 'f', 'g', 'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o', 'p', 'q', 'r', 's', 't', 'u', 'v', 'w', 'x', 'y', 'z'};
    long long n, k; cin >> n >> k;
    long long m = k/n, l = m + k%n;
    // scanf("%ll", &n, &k);
    string a; cin >> a;
    // scanf("%s", &a);
    string e = a; int c = 0;
    for(int i=0; i<n; i++){
        int t = int(a[i])-96;
        if(t<=13){
            if(i==n-1){e[i] = alph[t+l-1]; c+=l;}
            else{e[i] = alph[t+m-1]; c+=m;}
        }else{
            if(i==n-1){e[i] = alph[t-l-1]; c+=l;}
            else{e[i] = alph[t-m-1]; c+=m;}
        }
    }
    cout << e;
}


#include <iostream>
#include <fstream>
#include <algorithm>
#include <string>
#include <vector>
#include <stdio.h>
using namespace std;

int main(){
    ifstream cin("test.in");
    vector<char> alph = {'a', 'b', 'c', 'd', 'e', 'f', 'g', 'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o', 'p', 'q', 'r', 's', 't', 'u', 'v', 'w', 'x', 'y', 'z'};
    long long n, k; cin >> n >> k;
    long long m = k/n, l = m + k%n;
    // scanf("%ll", &n, &k);
    string a; cin >> a;
    // scanf("%s", &a);
    string e = a; int c = 0;
    for(int i=0; i<n; i++){
        int t = int(a[i])-96;
        if(t<=13){
            if(i==n-1){e[i] = alph[t+l-1]; c+=l;}
            else{e[i] = alph[t+m-1]; c+=m;}
        }else{
            if(i==n-1){e[i] = alph[t-l-1]; c+=l;}
            else{e[i] = alph[t-m-1]; c+=m;}
        }
    }
    cout << e;
}


#include <iostream>
#include <fstream>
#include <algorithm>
#include <string>
#include <vector>
#include <stdio.h>
using namespace std;

int main(){
    vector<char> alph = {'a', 'b', 'c', 'd', 'e', 'f', 'g', 'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o', 'p', 'q', 'r', 's', 't', 'u', 'v', 'w', 'x', 'y', 'z'};
    long long n, k; cin >> n >> k;
    // scanf("%ll", &n, &k);
    string a; cin >> a;
    // scanf("%s", &a);
    string e = a; int c = 0;
    for(int i=0; i<n; i++){
        int t = int(a[i])-96;
        if(c==k){
            break;
        }else if(t<=13){
            e[i] = 'z';
            int d = c;
            c += 26 - t;
            if(c>k){
                c = d;
                int f = k - c;
                e[i] = alph[(t-1)+f];
                c += abs(f-(t-1));
            }
        }else{
            e[i] = 'a';
            c += t - 1;
        }
        // cout << t << " " << e[i] << " " << c << " " << i << endl;
    }
    if(c!=k){
        cout << -1;
        return 0;
    }
    cout << e;
}


#include <iostream>
#include <fstream>
#include <algorithm>
#include <string>
#include <vector>
#include <stdio.h>
using namespace std;

int main(){
    vector<char> alph = {'a', 'b', 'c', 'd', 'e', 'f', 'g', 'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o', 'p', 'q', 'r', 's', 't', 'u', 'v', 'w', 'x', 'y', 'z'};
    long long n, k; cin >> n >> k;
    // scanf("%ll", &n, &k);
    string a; cin >> a;
    // scanf("%s", &a);
    string e = a; int c = 0;
    for(int i=0; i<n; i++){
        int t = int(a[i])-96;
        if(c==k){
            break;
        }else if(t<=13){
            e[i] = 'z';
            int d = c;
            c += 26 - t;
            if(c>k){
                c = d;
                int f = k - c;
                e[i] = alph[(t-1)+f];
                c += f;
            }
        }else{
            e[i] = 'a';
            int d = c;
            c += t - 1;
            if(c>k){
                c = d;
                int f = k - c;
                e[i] = alph[(t-1)-f];
                c += f;
            }
        }
        // cout << t << " " << e[i] << " " << c << " " << i << endl;
    }
    if(c!=k){
        cout << -1;
        return 0;
    }
    cout << e;
}


#include <iostream>
#include <fstream>
#include <algorithm>
#include <string>
#include <vector>
#include <stdio.h>
using namespace std;

int main(){
    // ifstream cin("test.in");
    vector<char> alph = {'a', 'b', 'c', 'd', 'e', 'f', 'g', 'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o', 'p', 'q', 'r', 's', 't', 'u', 'v', 'w', 'x', 'y', 'z'};
    long long n, k; cin >> n >> k;
    long long m = k/n, l = m + k%n;
    // scanf("%ll", &n, &k);
    string a; cin >> a;
    // scanf("%s", &a);
    string e = a; int c = 0;
    for(int i=0; i<n; i++){
        int t; cin >> t;
        if(t<=13){
            if(i==n-1){e[i] = alph[t+l-1]; c+=l;}
            else{e[i] = alph[t+m-1]; c+=m;}
        }else{
            if(i==n-1){e[i] = alph[t-l-1]; c+=l;}
            else{e[i] = alph[t-m-1]; c+=m;}
        }
    }
    cout << e;
}


#include<iostream>
#include<algorithm>
#include<vector>
#include<map>
#include<set>
#include<queue>
#include<stack>
#include<numeric>
#include<math.h>
#define ld long double
#define ll long long int
#define max(a,b) a>b?a:b
#define min(a,b) a<b?a:b
#define fi(a,b,c) for(int a=b;a<c;a++)
#define fd(a,b,c) for(int a=b;a>c;a--)
using namespace std;
int n,k;
char s[100009];
int main(){
   cin>>n>>k;
   cin>>s;
   int i=0;
   int t=0;
   while(k&&(i<n)){
      if(s[i]<'n'){
         t=min(k,122-s[i]);
         s[i]+=t;
      }else{
         t=min(k,s[i]-97);
         s[i]-=t;
      }
      k-=(int)t;
      i++;
   }
   if(k){
      cout<<-1;return 0;
   }
   cout<<s;
}


#include<iostream>
#include<algorithm>
#include<vector>
#include<map>
#include<set>
#include<queue>
#include<stack>
#include<numeric>
#include<math.h>
#define ld long double
#define ll long long int
#define max(a,b) a>b?a:b
#define min(a,b) a<b?a:b
#define fi(a,b,c) for(int a=b;a<c;a++)
#define fd(a,b,c) for(int a=b;a>c;a--)
using namespace std;
int n,k;
char s[100009];
int main(){
   cin>>n>>k;
   cin>>s;
   int sum=0;
   fi(i,0,n){
      sum+=s[i]-96;
   }
   if(k>n*26-sum & k>sum-n){
      cout<<-1;return 0;
   }
   int i=0;
   int t=0;
   if(k<=n*26-sum){
      while(k){
         t=min(k,122-s[i]);
         s[i]+=t;
         k-=(int)t;
         i++;
      }
   }else if(k<=sum-n){
      while(k){
         t=min(k,s[i]-97);
         s[i]-=t;
         k-=(int)t;
         i++;
      }
   }
   cout<<s;
}


#include <bits/stdc++.h>
#define rep(i,a,b) for(int i=a;i<=b;++i)
#define rev(i,a,b) for(int i=a;i>=b;--i)
template <typename T> inline bool smax(T &a,T b) { return a < b ? a = b, 1 : 0 ;}
template <typename T> inline bool smin(T &a,T b) { return a > b ? a = b, 1 : 0 ;}
using namespace std;
int n, k;
const int N = 150100;
int cnt[N];
string s[N];
string a[] = {"A","B","C","D","E","F","G","H","I","J","K","L","M","N","O","P","Q","R","S","T","U","V","W","X","Y","Z","AB","BC","CD","DE","EF","FG","GH","HI","IJ","JK","KL","LM","MN","NO","OP","PQ","QR","RS","ST","TU","UV","VW","WX","XY","YZ","ZZ"};
string res[N];
int main(){
	cin>>n>>k;
	int cur = 0;
	bool found = 0;
	rep(i,0,n-1) {
		res[i]="";
	}
	rep(i,1,n-k+1) {
		cin >> s[i];
		if(s[i] == "YES") {
			found = 1;
			rep(j,1,k){
				if(res[i+j-1].length() == 0){
					res[i+j-1]=a[cur++];
				}
			}
		}
	}
	rep(i,1,n-k+1){
		if(s[i]=="NO"){
			if(i-1 >= 1 && i+1 <= n-k+1){
				if(s[i-1]=="NO" && s[i+1] == "NO"){
					rep(j,1,k) res[i+j-1]="FUCK";
				} else if(s[i-1] == "NO" && s[i+1] == "YES" && res[i]=="") {
					res[i]=res[i+1];
				} else if(s[i-1] == "YES" && s[i+1] == "NO" && res[i]=="") {
					res[i]=res[i-1];
				} else {
					res[i]=res[i+k-1];
				}
			} else if(i-1 < 1){
				if(s[i+1] == "YES" && res[i] == "") res[i]=res[i+1];
				else rep(j,1,k)res[i+j-1]="FF";
			} else res[i+k-1]=res[i+k-2];
		}
	}
	if(!found) {
		rep(i,1,n) {
			printf("Fuck ");
		}
		return 0;
	}
	rep(i,1,n) {
		string s = res[i];
		int n = s.length();
		cout<<s[0];
		rep(j,1,n-1) cout<<(char)tolower(s[j]);
		cout<<" ";
	}
}


#include <bits/stdc++.h>
using namespace std;
typedef long long ll;
ll i,j,n,m,k,ch,d;
char c;
string s[1000],str;
int main()
{
    cin >> n >> k;
    for(i=0;i<n;i++)
    {
        ch=65+i;
        c=ch;
        d=65+i;
    if(n>25)s[i]=c+d;
    else s[i]=c;
    }
    for(i=0;i<n-k+1;i++)
    {

        cin >> str;
        if(str=="NO")
        {
            s[i+k-1]=s[i];
        }
    }
for(i=0;i<n-1;i++)
{
    cout << s[i] << " ";
}
cout << s[i] << endl;

    return 0;
}


#include <bits/stdc++.h>
using namespace std;
typedef long long ll;
ll i,j,n,m,k,ch,d,h,ff;
char c;
string s[1000],str;
int main()
{
    cin >> n >> k;
    for(i=0;i<n;i++,h++)
    {
      s[i]="TheBoat";
      s[i][0]+=i/26;
      s[i][1]+=i%26;
    }
    for(i=0;i<n-k+1;i++)
    {

        cin >> str;
        if(str=="NO")
        {
            s[i+k-1]=s[i];
        }
    }
for(i=0;i<n-1;i++)
{
    cout << s[i] << " ";
}
cout << s[i] << endl;

    return 0;
}


#include <bits/stdc++.h>
using namespace std;
typedef long long ll;
ll i,j,n,m,k,ch,d,h,ff;
char c;
string s[1000],str;
int main()
{
    cin >> n >> k;
    for(i=0;i<n;i++,h++)
    {
        ch=65+h;
        c=ch;
        d=65+h;

     s[i]=c;
    if(i>25)s[i]+=d;
    if(i>25 and ff==0){h=0;ff=1;}
    }
    for(i=0;i<n-k+1;i++)
    {

        cin >> str;
        if(str=="NO")
        {
            s[i+k-1]=s[i];
        }
    }
for(i=0;i<n-1;i++)
{
    cout << s[i] << " ";
}
cout << s[i] << endl;

    return 0;
}


#include <bits/stdc++.h>
using namespace std;
typedef long long ll;
ll i,j,n,m,k,ch,d,h,ff;
char c;
string s[1000],str;
int main()
{
    cin >> n >> k;
    for(i=0;i<n;i++,h++)
    {
      s[i]="Aa_tbm";
      s[i][0]+=i/26;
      s[i][1]+=i%26;
    }
    for(i=0;i<n-k+1;i++)
    {

        cin >> str;
        if(str=="NO")
        {
            s[i+k-1]=s[i];
        }
    }
for(i=0;i<n-1;i++)
{
    cout << s[i] << " ";
}
cout << s[i] << endl;
return 0;
}


#include <bits/stdc++.h>
using namespace std;
typedef long long ll;
ll i,j,n,m,k,ch,d,h,ff;
char c;
string s[1000],str;
int main()
{
    cin >> n >> k;
    for(i=0;i<n;i++,h++)
    {
      s[i]="Theboatman";
      s[i][0]+=i/26;
      s[i][1]+=i%26;
    }
    for(i=0;i<n-k+1;i++)
    {

        cin >> str;
        if(str=="NO")
        {
            s[i+k-1]=s[i];
        }
    }
for(i=0;i<n-1;i++)
{
    cout << s[i] << " ";
}
cout << s[i] << endl;

    return 0;
}


#include <bits/stdc++.h>
using namespace std;
typedef long long ll;
ll i,j,n,m,k,ch,d;
char c;
string s[1000],str;
int main()
{
    cin >> n >> k;
    for(i=0;i<n;i++)
    {
        ch=65+i;
        c=ch;
        d=65+i;
    if(n>25)s[i]=c+d;
    else s[i]=c;
    }
    for(i=0;i<n-k+1;i++)
    {

        cin >> str;
        if(str=="NO")
        {
            s[i]=s[i+k-1];
        }
    }
for(i=0;i<n-1;i++)
{
    cout << s[i] << " ";
}
cout << s[i] << endl;

    return 0;
}


#include <iostream>
#include <cstdio>
using namespace std;
long long n,i,e,o1,o2,f,o3,o4,k,j;
string s;
char c;
int main()
{
   // freopen("input.txt", "r", stdin);
   // freopen("output.txt", "w", stdout);
    ios_base :: sync_with_stdio(0);
    cin.tie(0);
    cin >> n >> k;
    for(i=0;i<n-k+1;i++)
    {
        cin >> s;
        if(s=="YES")
        {
            for(j=0;j<k;j++)
            {
                c=65+j;
                cout << c << " ";
            }
        }
        else
        {
            c=65;
            cout << c << " ";
            for(j=0;j<k-1;j++)
            {
                c=65+j;
                cout << c << " ";
            }
        }
    }
    return 0;
}


#include <bits/stdc++.h>
using namespace std;
typedef long long ll;
ll i,j,n,m,k,ch,d,h,ff;
char c;
string s[1000],str;
int main()
{
    cin >> n >> k;
    for(i=0;i<n;i++,h++)
    {
      s[i]="Aatbm";
      s[i][0]+=i/26;
      s[i][1]+=i%26;
    }
    for(i=0;i<n-k+1;i++)
    {

        cin >> str;
        if(str=="NO")
        {
            s[i+k-1]=s[i];
        }
    }
for(i=0;i<n-1;i++)
{
    cout << s[i] << " ";
}
cout << s[i] << endl;
return 0;
}


#include <bits/stdc++.h>
using namespace std;
typedef long long ll;
ll i,j,n,m,k,ch,d,h,ff;
char c;
string s[1000],str;
int main()
{
    cin >> n >> k;
    for(i=0;i<n;i++,h++)
    {
      s[i]="Aa_tbm";
      s[i][0]+=i/26;
      s[i][1]+=i%26;
    }
    for(i=0;i<n-k+1;i++)
    {

        cin >> str;
        if(str=="NO")
        {
            s[i+k-1]=s[i];
        }
    }
for(i=0;i<n-1;i++)
{
    cout << s[i] << " ";
}
cout << s[i] << endl;


#define _CRT_SECURE_NO_WARNINGS

#pragma GCC optimize("Ofast")
#pragma GCC optimize("O4")
#pragma GCC optimize("no-stack-protector")
#pragma GCC optimize("unroll-loops")
#pragma GCC optimize("unswitch-loops")
#pragma GCC optimize("fast-math")
#pragma GCC optimize("tracer")
#pragma GCC target("sse2")
#pragma GCC target("sse3")
#pragma GCC target("popcnt")
#pragma GCC target("abm")
#pragma GCC target("mmx")
#pragma GCC target("tune=native")

#include <cstdio>
#include <vector>
#include <functional>
#include <string>
#include <algorithm>
#include <set>
#include <map>
#include <set>
#include <cstdlib>
#include <cassert>
#include <unordered_map>
#include <unordered_set>
#include <queue>
#include <numeric>
#include <deque>
#include <random>
#include <chrono>
#include <ctime>
#include <climits>
#include <stack>
#include <array>
#include <iomanip>
#include <complex>
#include <bitset>
#include <iostream>
#include <cstring>

using namespace std;
using ll = long long;
using ld = long double;
using ull = unsigned long long;

#define all(a) a.begin(), a.end()
#define len(a) (int)a.size()
#define pb push_back
#define eb emplace_back
#define em emplace
#define y0 withindarkness
#define y1 apinklotusbloomed
#define yn carryingapurplesoul
#define j1 togetherformingtheTeam

void useiostream() {
	ios_base::sync_with_stdio(false), cin.tie(0), cout.tie(0);
	cout.setf(ios::fixed), cout.precision(8);
}

void drop(char const* bu) {
	printf("%s", bu);
	exit(0);
}

ull gcd(ull a, ull b) {
	return b == 0 ? a : gcd(b, a % b);
}

ll lcm(ll a, ll b) {
	return a / gcd(a, b) * b;
}

ld const pi = acos(-1.0L);
ld const eps = 0.0001L;

template<typename T, typename TT> bool mi(T& a, TT b) { return a > b ? (a = b, true) : false; }
template<typename T, typename TT> bool ma(T& a, TT b) { return a < b ? (a = b, true) : false; }

mt19937 ran(996);

int const mod = 1000000007;

ull bm(ull a, ull p, ull mod) {
	return (a * p - (ll)((ld)a * p / mod) * mod + mod) % mod;
}

ull bp(ull a, ull p, ull mod) {
	ull re = 1;
	while (p) {
		if (p & 1)re = bm(re, a, mod);
		p >>= 1;
		a = bm(a, a, mod);
	}
	return re;
}

bool test(ull n) {
	ull p = 0;
	while ((n - 1) % (1ULL << p) == 0)p++;
	p--;
	ull t = (n - 1) / (1ULL << p);
	int cnt = 0;
	for (int k = 0; k < 20; k++) {
		ull a = ran();
		a %= n - 3;
		a += 2;
		ull x = bp(a, t, n);
		if (x == 1 || x == n - 1)continue;
		for (int j = 0; j < p - 1; j++) {
			x = bp(x, 2, n);
			if (x == 1)return true;
			if (x == n - 1) {
				cnt++;
			}
		}
		return true;
	}
	return false;
}

ull rho(ull a) {
	ull x = rand();
	x %= a - 2;
	x += 1;
	ull y = 1, i = 0, stage = 2;
	while (gcd(a, max(x, y) - min(x, y)) == 1) {
		if (i == stage) {
			y = x;
			stage *= 2;
		}
		x = bp(x, 2, a);
		if (x == 0)x = a - 1;
		else x--;
		i++;
	}
	return gcd(a, max(x, y) - min(x, y));
}

int n, k;
string res[55];
bool yes[55];

pair<int, int> get(string str) {
	return { str[0] - 'A', str[1] - 'a' };
}

string get(pair<int, int> p) {
	string re;
	re += 'A' + p.first;
	re += 'a' + p.second;
	return re;
}

int main() {
	useiostream();
#ifdef _DEBUG
	(void)freopen("input.txt", "r", stdin);
	(void)freopen("output.txt", "w", stdout);
#else
	//(void)freopen("bisector.in", "r", stdin);
	//(void)freopen("bisector.out", "w", stdout);
#endif

	cin >> n >> k;
	int has = -1;
	for (int i = 0; i < n-k+1; i++) {
		string str;
		cin >> str;
		yes[i] = str == "YES";
		if (yes[i] && has ==-1)has = i;
	}
	if (has == -1) {
		for (int i = 0; i < n; i++) {
			cout << "A ";
		}
		return 0;
	}

	set<pair<int, int> > use;

	for (int i = 0; i < 26; i++) {
		for (int j = 0; j < 26; j++) {
			use.insert({ i, j });
		}
	}

	for (int i = has; i < has + k; i++) {
		string keka = get(*use.begin());
		use.erase(use.begin());

		res[i] = keka;

	}

	for (int j = 0; j < has; j++) {
		res[j] = "Aa";
	}

	for (int i = has + 1; i <= n - k; i++) {
		use.insert(get(res[i - 1]));

		if (yes[i]) {
			res[i + k - 1] = get(*use.begin());
			use.erase(use.begin());
		}
		else {
			res[i + k - 1] = res[i];
		}
	}
	for (int i = 0; i < n; i++) {
		cout << res[i] << " ";
	}
	return 0;
}


#define _CRT_SECURE_NO_WARNINGS

#pragma GCC optimize("Ofast")
#pragma GCC optimize("O4")
#pragma GCC optimize("no-stack-protector")
#pragma GCC optimize("unroll-loops")
#pragma GCC optimize("unswitch-loops")
#pragma GCC optimize("fast-math")
#pragma GCC optimize("tracer")
#pragma GCC target("sse2")
#pragma GCC target("sse3")
#pragma GCC target("popcnt")
#pragma GCC target("abm")
#pragma GCC target("mmx")
#pragma GCC target("tune=native")

#include <cstdio>
#include <vector>
#include <functional>
#include <string>
#include <algorithm>
#include <set>
#include <map>
#include <set>
#include <cstdlib>
#include <cassert>
#include <unordered_map>
#include <unordered_set>
#include <queue>
#include <numeric>
#include <deque>
#include <random>
#include <chrono>
#include <ctime>
#include <climits>
#include <stack>
#include <array>
#include <iomanip>
#include <complex>
#include <bitset>
#include <iostream>
#include <cstring>

using namespace std;
using ll = long long;
using ld = long double;
using ull = unsigned long long;

#define all(a) a.begin(), a.end()
#define len(a) (int)a.size()
#define pb push_back
#define eb emplace_back
#define em emplace
#define y0 withindarkness
#define y1 apinklotusbloomed
#define yn carryingapurplesoul
#define j1 togetherformingtheTeam

void useiostream() {
	ios_base::sync_with_stdio(false), cin.tie(0), cout.tie(0);
	cout.setf(ios::fixed), cout.precision(8);
}

void drop(char const* bu) {
	printf("%s", bu);
	exit(0);
}

ull gcd(ull a, ull b) {
	return b == 0 ? a : gcd(b, a % b);
}

ll lcm(ll a, ll b) {
	return a / gcd(a, b) * b;
}

ld const pi = acos(-1.0L);
ld const eps = 0.0001L;

template<typename T, typename TT> bool mi(T& a, TT b) { return a > b ? (a = b, true) : false; }
template<typename T, typename TT> bool ma(T& a, TT b) { return a < b ? (a = b, true) : false; }

mt19937 ran(996);

int const mod = 1000000007;

ull bm(ull a, ull p, ull mod) {
	return (a * p - (ll)((ld)a * p / mod) * mod + mod) % mod;
}

ull bp(ull a, ull p, ull mod) {
	ull re = 1;
	while (p) {
		if (p & 1)re = bm(re, a, mod);
		p >>= 1;
		a = bm(a, a, mod);
	}
	return re;
}

bool test(ull n) {
	ull p = 0;
	while ((n - 1) % (1ULL << p) == 0)p++;
	p--;
	ull t = (n - 1) / (1ULL << p);
	int cnt = 0;
	for (int k = 0; k < 20; k++) {
		ull a = ran();
		a %= n - 3;
		a += 2;
		ull x = bp(a, t, n);
		if (x == 1 || x == n - 1)continue;
		for (int j = 0; j < p - 1; j++) {
			x = bp(x, 2, n);
			if (x == 1)return true;
			if (x == n - 1) {
				cnt++;
			}
		}
		return true;
	}
	return false;
}

ull rho(ull a) {
	ull x = rand();
	x %= a - 2;
	x += 1;
	ull y = 1, i = 0, stage = 2;
	while (gcd(a, max(x, y) - min(x, y)) == 1) {
		if (i == stage) {
			y = x;
			stage *= 2;
		}
		x = bp(x, 2, a);
		if (x == 0)x = a - 1;
		else x--;
		i++;
	}
	return gcd(a, max(x, y) - min(x, y));
}

int n, k;
string res[55];
bool yes[55];

pair<int, int> get(string str) {
	return { str[0] - 'a', str[1] - 'a' };
}

string get(pair<int, int> p) {
	string re;
	re += 'a' + p.first;
	re += 'a' + p.second;
	return re;
}

int main() {
	useiostream();
#ifdef _DEBUG
	(void)freopen("input.txt", "r", stdin);
	(void)freopen("output.txt", "w", stdout);
#else
	//(void)freopen("bisector.in", "r", stdin);
	//(void)freopen("bisector.out", "w", stdout);
#endif

	cin >> n >> k;
	int has = -1;
	for (int i = 0; i < n-k+1; i++) {
		string str;
		cin >> str;
		yes[i] = str == "YES";
		if (yes[i] && has ==-1)has = i;
	}
	if (has == -1) {
		for (int i = 0; i < n; i++) {
			cout << "a ";
		}
		return 0;
	}

	set<pair<int, int> > use;

	for (int i = 0; i < 26; i++) {
		for (int j = 0; j < 26; j++) {
			use.insert({ i, j });
		}
	}

	for (int i = has; i < has + k; i++) {
		string keka = get(*use.begin());
		use.erase(use.begin());

		res[i] = keka;

	}

	for (int j = 0; j < has; j++) {
		res[j] = "aa";
	}

	for (int i = has + 1; i <= n - k; i++) {
		if (yes[i]) {
			res[i + k - 1] = get(*use.begin());
			use.erase(use.begin());
		}
		else {
			res[i + k - 1] = res[i];
		}
		use.insert(get(res[i - 1]));
	}
	for (int i = 0; i < n; i++) {
		cout << res[i] << " ";
	}
	return 0;
}


#define _CRT_SECURE_NO_WARNINGS

#pragma GCC optimize("Ofast")
#pragma GCC optimize("O4")
#pragma GCC optimize("no-stack-protector")
#pragma GCC optimize("unroll-loops")
#pragma GCC optimize("unswitch-loops")
#pragma GCC optimize("fast-math")
#pragma GCC optimize("tracer")
#pragma GCC target("sse2")
#pragma GCC target("sse3")
#pragma GCC target("popcnt")
#pragma GCC target("abm")
#pragma GCC target("mmx")
#pragma GCC target("tune=native")

#include <cstdio>
#include <vector>
#include <functional>
#include <string>
#include <algorithm>
#include <set>
#include <map>
#include <set>
#include <cstdlib>
#include <cassert>
#include <unordered_map>
#include <unordered_set>
#include <queue>
#include <numeric>
#include <deque>
#include <random>
#include <chrono>
#include <ctime>
#include <climits>
#include <stack>
#include <array>
#include <iomanip>
#include <complex>
#include <bitset>
#include <iostream>
#include <cstring>

using namespace std;
using ll = long long;
using ld = long double;
using ull = unsigned long long;

#define all(a) a.begin(), a.end()
#define len(a) (int)a.size()
#define pb push_back
#define eb emplace_back
#define em emplace
#define y0 withindarkness
#define y1 apinklotusbloomed
#define yn carryingapurplesoul
#define j1 togetherformingtheTeam

void useiostream() {
	ios_base::sync_with_stdio(false), cin.tie(0), cout.tie(0);
	cout.setf(ios::fixed), cout.precision(8);
}

void drop(char const* bu) {
	printf("%s", bu);
	exit(0);
}

ull gcd(ull a, ull b) {
	return b == 0 ? a : gcd(b, a % b);
}

ll lcm(ll a, ll b) {
	return a / gcd(a, b) * b;
}

ld const pi = acos(-1.0L);
ld const eps = 0.0001L;

template<typename T, typename TT> bool mi(T& a, TT b) { return a > b ? (a = b, true) : false; }
template<typename T, typename TT> bool ma(T& a, TT b) { return a < b ? (a = b, true) : false; }

mt19937 ran(996);

int const mod = 1000000007;

ull bm(ull a, ull p, ull mod) {
	return (a * p - (ll)((ld)a * p / mod) * mod + mod) % mod;
}

ull bp(ull a, ull p, ull mod) {
	ull re = 1;
	while (p) {
		if (p & 1)re = bm(re, a, mod);
		p >>= 1;
		a = bm(a, a, mod);
	}
	return re;
}

bool test(ull n) {
	ull p = 0;
	while ((n - 1) % (1ULL << p) == 0)p++;
	p--;
	ull t = (n - 1) / (1ULL << p);
	int cnt = 0;
	for (int k = 0; k < 20; k++) {
		ull a = ran();
		a %= n - 3;
		a += 2;
		ull x = bp(a, t, n);
		if (x == 1 || x == n - 1)continue;
		for (int j = 0; j < p - 1; j++) {
			x = bp(x, 2, n);
			if (x == 1)return true;
			if (x == n - 1) {
				cnt++;
			}
		}
		return true;
	}
	return false;
}

ull rho(ull a) {
	ull x = rand();
	x %= a - 2;
	x += 1;
	ull y = 1, i = 0, stage = 2;
	while (gcd(a, max(x, y) - min(x, y)) == 1) {
		if (i == stage) {
			y = x;
			stage *= 2;
		}
		x = bp(x, 2, a);
		if (x == 0)x = a - 1;
		else x--;
		i++;
	}
	return gcd(a, max(x, y) - min(x, y));
}

int n, k;
string res[55];
bool yes[55];

pair<int, int> get(string str) {
	return { str[0] - 'A', str[1] - 'a' };
}

string get(pair<int, int> p) {
	string re;
	re += 'A' + p.first;
	re += 'a' + p.second;
	return re;
}

int main() {
	useiostream();
#ifdef _DEBUG
	(void)freopen("input.txt", "r", stdin);
	(void)freopen("output.txt", "w", stdout);
#else
	//(void)freopen("bisector.in", "r", stdin);
	//(void)freopen("bisector.out", "w", stdout);
#endif

	cin >> n >> k;
	int has = -1;
	for (int i = 0; i < n-k+1; i++) {
		string str;
		cin >> str;
		yes[i] = str == "YES";
		if (yes[i] && has ==-1)has = i;
	}
	if (has == -1) {
		for (int i = 0; i < n; i++) {
			cout << "A ";
		}
		return 0;
	}

	for (int i = has; i < has + k; i++) {
		set<string> used;
		for (int j = has; j < i; j++) {
			used.insert(res[j]);
		}
		for (int a = 0; a < 26; a++) {
			for (int b = 0; b < 26; b++) {
				if (!used.count(get(pair<int, int>(a, b)))) {
					res[i] = get(pair<int, int >(a, b));
				}
			}
		}
	}

	for (int j = 0; j < has; j++) {
		res[j] = "Aa";
	}

	for (int i = has + 1; i <= n - k; i++) {

		set<string> used;

		if (yes[i]) {
			for (int j = i; j < i + k - 1; j++) {
				used.insert(res[j]);
			}
			for (int a = 0; a < 26; a++) {
				for (int b = 0; b < 26; b++) {
					if (!used.count(get(pair<int, int>(a, b)))) {
						res[i + k - 1] = get(pair<int, int >(a, b));
					}
				}
			}
		}
		else {
			res[i + k - 1] = res[i];
		}
	}
	for (int i = 0; i < n; i++) {
		cout << res[i] << " ";
	}
	return 0;
}


#define _CRT_SECURE_NO_WARNINGS

#pragma GCC optimize("Ofast")
#pragma GCC optimize("O4")
#pragma GCC optimize("no-stack-protector")
#pragma GCC optimize("unroll-loops")
#pragma GCC optimize("unswitch-loops")
#pragma GCC optimize("fast-math")
#pragma GCC optimize("tracer")
#pragma GCC target("sse2")
#pragma GCC target("sse3")
#pragma GCC target("popcnt")
#pragma GCC target("abm")
#pragma GCC target("mmx")
#pragma GCC target("tune=native")

#include <cstdio>
#include <vector>
#include <functional>
#include <string>
#include <algorithm>
#include <set>
#include <map>
#include <set>
#include <cstdlib>
#include <cassert>
#include <unordered_map>
#include <unordered_set>
#include <queue>
#include <numeric>
#include <deque>
#include <random>
#include <chrono>
#include <ctime>
#include <climits>
#include <stack>
#include <array>
#include <iomanip>
#include <complex>
#include <bitset>
#include <iostream>
#include <cstring>

using namespace std;
using ll = long long;
using ld = long double;
using ull = unsigned long long;

#define all(a) a.begin(), a.end()
#define len(a) (int)a.size()
#define pb push_back
#define eb emplace_back
#define em emplace
#define y0 withindarkness
#define y1 apinklotusbloomed
#define yn carryingapurplesoul
#define j1 togetherformingtheTeam

void useiostream() {
	ios_base::sync_with_stdio(false), cin.tie(0), cout.tie(0);
	cout.setf(ios::fixed), cout.precision(8);
}

void drop(char const* bu) {
	printf("%s", bu);
	exit(0);
}

ull gcd(ull a, ull b) {
	return b == 0 ? a : gcd(b, a % b);
}

ll lcm(ll a, ll b) {
	return a / gcd(a, b) * b;
}

ld const pi = acos(-1.0L);
ld const eps = 0.0001L;

template<typename T, typename TT> bool mi(T& a, TT b) { return a > b ? (a = b, true) : false; }
template<typename T, typename TT> bool ma(T& a, TT b) { return a < b ? (a = b, true) : false; }

mt19937 ran(996);

int const mod = 1000000007;

ull bm(ull a, ull p, ull mod) {
	return (a * p - (ll)((ld)a * p / mod) * mod + mod) % mod;
}

ull bp(ull a, ull p, ull mod) {
	ull re = 1;
	while (p) {
		if (p & 1)re = bm(re, a, mod);
		p >>= 1;
		a = bm(a, a, mod);
	}
	return re;
}

bool test(ull n) {
	ull p = 0;
	while ((n - 1) % (1ULL << p) == 0)p++;
	p--;
	ull t = (n - 1) / (1ULL << p);
	int cnt = 0;
	for (int k = 0; k < 20; k++) {
		ull a = ran();
		a %= n - 3;
		a += 2;
		ull x = bp(a, t, n);
		if (x == 1 || x == n - 1)continue;
		for (int j = 0; j < p - 1; j++) {
			x = bp(x, 2, n);
			if (x == 1)return true;
			if (x == n - 1) {
				cnt++;
			}
		}
		return true;
	}
	return false;
}

ull rho(ull a) {
	ull x = rand();
	x %= a - 2;
	x += 1;
	ull y = 1, i = 0, stage = 2;
	while (gcd(a, max(x, y) - min(x, y)) == 1) {
		if (i == stage) {
			y = x;
			stage *= 2;
		}
		x = bp(x, 2, a);
		if (x == 0)x = a - 1;
		else x--;
		i++;
	}
	return gcd(a, max(x, y) - min(x, y));
}

int n, k;
string res[55];
bool yes[55];

pair<int, int> get(string str) {
	return { str[0] - 'A', str[1] - 'a' };
}

string get(pair<int, int> p) {
	string re;
	re += 'A' + p.first;
	re += 'a' + p.second;
	return re;
}

int main() {
	useiostream();
#ifdef _DEBUG
	(void)freopen("input.txt", "r", stdin);
	(void)freopen("output.txt", "w", stdout);
#else
	//(void)freopen("bisector.in", "r", stdin);
	//(void)freopen("bisector.out", "w", stdout);
#endif

	cin >> n >> k;
	int has = -1;
	for (int i = 0; i < n-k+1; i++) {
		string str;
		cin >> str;
		yes[i] = str == "YES";
		if (yes[i] && has ==-1)has = i;
	}
	if (has == -1) {
		for (int i = 0; i < n; i++) {
			cout << "A ";
		}
		return 0;
	}

	set<pair<int, int> > use;

	for (int i = 0; i < 26; i++) {
		for (int j = 0; j < 26; j++) {
			use.insert({ i, j });
		}
	}

	for (int i = has; i < has + k; i++) {
		string keka = get(*use.begin());
		use.erase(use.begin());

		res[i] = keka;

	}

	for (int j = 0; j < has; j++) {
		res[j] = "Aa";
	}

	for (int i = has + 1; i <= n - k; i++) {
		if (yes[i]) {
			res[i + k - 1] = get(*use.begin());
			use.erase(use.begin());
		}
		else {
			res[i + k - 1] = res[i];
		}
		use.insert(get(res[i - 1]));
	}
	for (int i = 0; i < n; i++) {
		cout << res[i] << " ";
	}
	return 0;
}


#define _CRT_SECURE_NO_WARNINGS

#pragma GCC optimize("Ofast")
#pragma GCC optimize("O4")
#pragma GCC optimize("no-stack-protector")
#pragma GCC optimize("unroll-loops")
#pragma GCC optimize("unswitch-loops")
#pragma GCC optimize("fast-math")
#pragma GCC optimize("tracer")
#pragma GCC target("sse2")
#pragma GCC target("sse3")
#pragma GCC target("popcnt")
#pragma GCC target("abm")
#pragma GCC target("mmx")
#pragma GCC target("tune=native")

#include <cstdio>
#include <vector>
#include <functional>
#include <string>
#include <algorithm>
#include <set>
#include <map>
#include <set>
#include <cstdlib>
#include <cassert>
#include <unordered_map>
#include <unordered_set>
#include <queue>
#include <numeric>
#include <deque>
#include <random>
#include <chrono>
#include <ctime>
#include <climits>
#include <stack>
#include <array>
#include <iomanip>
#include <complex>
#include <bitset>
#include <iostream>
#include <cstring>

using namespace std;
using ll = long long;
using ld = long double;
using ull = unsigned long long;

#define all(a) a.begin(), a.end()
#define len(a) (int)a.size()
#define pb push_back
#define eb emplace_back
#define em emplace
#define y0 withindarkness
#define y1 apinklotusbloomed
#define yn carryingapurplesoul
#define j1 togetherformingtheTeam

void useiostream() {
	ios_base::sync_with_stdio(false), cin.tie(0), cout.tie(0);
	cout.setf(ios::fixed), cout.precision(8);
}

void drop(char const* bu) {
	printf("%s", bu);
	exit(0);
}

ull gcd(ull a, ull b) {
	return b == 0 ? a : gcd(b, a % b);
}

ll lcm(ll a, ll b) {
	return a / gcd(a, b) * b;
}

ld const pi = acos(-1.0L);
ld const eps = 0.0001L;

template<typename T, typename TT> bool mi(T& a, TT b) { return a > b ? (a = b, true) : false; }
template<typename T, typename TT> bool ma(T& a, TT b) { return a < b ? (a = b, true) : false; }

mt19937 ran(996);

int const mod = 1000000007;

ull bm(ull a, ull p, ull mod) {
	return (a * p - (ll)((ld)a * p / mod) * mod + mod) % mod;
}

ull bp(ull a, ull p, ull mod) {
	ull re = 1;
	while (p) {
		if (p & 1)re = bm(re, a, mod);
		p >>= 1;
		a = bm(a, a, mod);
	}
	return re;
}

bool test(ull n) {
	ull p = 0;
	while ((n - 1) % (1ULL << p) == 0)p++;
	p--;
	ull t = (n - 1) / (1ULL << p);
	int cnt = 0;
	for (int k = 0; k < 20; k++) {
		ull a = ran();
		a %= n - 3;
		a += 2;
		ull x = bp(a, t, n);
		if (x == 1 || x == n - 1)continue;
		for (int j = 0; j < p - 1; j++) {
			x = bp(x, 2, n);
			if (x == 1)return true;
			if (x == n - 1) {
				cnt++;
			}
		}
		return true;
	}
	return false;
}

ull rho(ull a) {
	ull x = rand();
	x %= a - 2;
	x += 1;
	ull y = 1, i = 0, stage = 2;
	while (gcd(a, max(x, y) - min(x, y)) == 1) {
		if (i == stage) {
			y = x;
			stage *= 2;
		}
		x = bp(x, 2, a);
		if (x == 0)x = a - 1;
		else x--;
		i++;
	}
	return gcd(a, max(x, y) - min(x, y));
}

int n, k;
string res[55];
bool yes[55];

pair<int, int> get(string str) {
	return { str[0] - 'A', str[1] - 'a' };
}

string get(pair<int, int> p) {
	string re;
	re += 'A' + p.first;
	re += 'a' + p.second;
	return re;
}

int main() {
	useiostream();
#ifdef _DEBUG
	(void)freopen("input.txt", "r", stdin);
	(void)freopen("output.txt", "w", stdout);
#else
	//(void)freopen("bisector.in", "r", stdin);
	//(void)freopen("bisector.out", "w", stdout);
#endif

	cin >> n >> k;
	int has = -1;
	for (int i = 0; i < n-k+1; i++) {
		string str;
		cin >> str;
		yes[i] = str == "YES";
		if (yes[i] && has ==-1)has = i;
	}
	if (has == -1) {
		for (int i = 0; i < n; i++) {
			cout << "A ";
		}
		return 0;
	}

	for (int i = has; i < has + k; i++) {
		set<string> used;
		for (int j = has; j < i; j++) {
			used.insert(res[j]);
		}
		for (int a = 0; a < 26; a++) {
			for (int b = 0; b < 26; b++) {
				if (!used.count(get(pair<int, int>(a, b)))) {
					res[i] = get(pair<int, int >(a, b));
				}
			}
		}
	}

	for (int j = 0; j < has; j++) {
		res[j] = "Zz";
	}

	for (int i = has + 1; i <= n - k; i++) {

		set<string> used;

		if (yes[i]) {
			for (int j = i; j < i + k - 1; j++) {
				used.insert(res[j]);
			}
			for (int a = 0; a < 26; a++) {
				for (int b = 0; b < 26; b++) {
					if (!used.count(get(pair<int, int>(a, b)))) {
						res[i + k - 1] = get(pair<int, int >(a, b));
					}
				}
			}
		}
		else {
			res[i + k - 1] = res[i];
		}
	}
	for (int i = 0; i < n; i++) {
		cout << res[i] << " ";
	}
	return 0;
}


#include <bits/stdc++.h>

using namespace std;

using VI = vector<int>;
using VVI = vector<VI>;
using VB = vector<bool>;
using VVB = vector<VB>;
using VD = vector<double>;
using VVD = vector<VD>;
using VS = vector<string>;
using PII = pair<int, int>;
using VPII = vector<PII>;
using VL = vector<long long>;
using VVL = vector<VL>;

#define sz(var) (int)var.size()
#define REP(var, start, end) for(int var = start; var < (int)end; ++var)
#define CLEAR(var, with) memset(var, with, sizeof(var))
#define ALL(x) x.begin(), x.end()
#define LL long long
#define ULL unsigned long long

int let = 0; int cnt = 1;
string generator()
{
	string ret(cnt, (char)(let + 'a'));
	ret[0] = toupper(ret[0]);
	if(let > 26)
		let = 0, ++cnt;
	++let;
	return ret;
}

int n, k;
void solve(VS& names)
{
	for(int i = 1; i <= n; ++i)
	{
		if(names[i] == "YES")
			names[i] = generator();
	}
	for(int i = 1; i + k - 1 <= n; ++i)
		if(names[i] == "NO" && names[i + k - 1] != "NO")
			names[i] = names[i + k - 1];
		else if(names[i] != "NO" && names[i + k - 1] == "NO")
			names[i + k - 1] = names[i];
		else if(names[i] == "NO" && names[i + k - 1] == "NO")
			names[i] = names[i + k - 1] = generator();

	for(int i = 1; i <= n; ++i)
		if(names[i] == "NO")
			names[i] = generator();
}

int main()
{
	ios_base::sync_with_stdio(false);
	cin.tie(0);
#ifndef ONLINE_JUDGE
	freopen("tmp.in", "r", stdin);
//	freopen("tmp.out", "w", stderr);
#endif
	cin >> n >> k;
	VS names = VS(n + 1, string(1, '?'));
	string s;
	for(int i = 1; i <= n - k + 1; ++i)
	{
		cin >> s;
		if(s == "YES") {
			for(int j = i; j <= i + k - 1; ++j)
			if(names[j] == "?")
				names[j] = "YES";
		}
		else {
			for(int j = i; j <= i + k - 1; ++j)
				if(names[j] == "?")
					names[j] = "NO";
		}
	}

	solve(names);
	for(int i = 1; i <= n; ++i)
		cout << names[i] << " ";
	cout << endl;

	return 0;
}


#include <bits/stdc++.h>

using namespace std;

using VI = vector<int>;
using VVI = vector<VI>;
using VB = vector<bool>;
using VVB = vector<VB>;
using VD = vector<double>;
using VVD = vector<VD>;
using VS = vector<string>;
using PII = pair<int, int>;
using VPII = vector<PII>;
using VL = vector<long long>;
using VVL = vector<VL>;

#define sz(var) (int)var.size()
#define REP(var, start, end) for(int var = start; var < (int)end; ++var)
#define CLEAR(var, with) memset(var, with, sizeof(var))
#define ALL(x) x.begin(), x.end()
#define LL long long
#define ULL unsigned long long

int let = 0; int cnt = 1;
string generator()
{
	string ret(cnt, (char)(let + 'a'));
	ret[0] = toupper(ret[0]);
	if(let > 26)
		let = 0, ++cnt;
	++let;
	return ret;
}

int n, k;
void solve(VS& names)
{
	for(int i = 1; i <= n; ++i)
	{
		if(names[i] == "YES")
			names[i] = generator();
	}
	for(int i = 1; i + k - 1 <= n; ++i)
		if(names[i] == "NO" && names[i + k - 1] != "NO")
			names[i] = names[i + k - 1];
		else if(names[i] != "NO" && names[i + k - 1] == "NO")
			names[i + k - 1] = names[i];
		else if(names[i] == "NO" && names[i + k - 1] == "NO")
			names[i] = names[i + k - 1] = generator();
}

int main()
{
	ios_base::sync_with_stdio(false);
	cin.tie(0);
#ifndef ONLINE_JUDGE
	freopen("tmp.in", "r", stdin);
//	freopen("tmp.out", "w", stderr);
#endif
	cin >> n >> k;
	VS names = VS(n + 1, string(1, '?'));
	string s;
	for(int i = 1; i <= n - k + 1; ++i)
	{
		cin >> s;
		if(s == "YES") {
			for(int j = i; j <= i + k - 1; ++j)
			if(names[j] == "?")
				names[j] = "YES";
		}
		else {
			for(int j = i; j <= i + k - 1; ++j)
				if(names[j] == "?")
					names[j] = "NO";
		}
	}

	solve(names);
	for(int i = 1; i <= n; ++i)
		cout << names[i] << " ";
	cout << endl;

	return 0;
}


#include <bits/stdc++.h>

using namespace std;

using VI = vector<int>;
using VVI = vector<VI>;
using VB = vector<bool>;
using VVB = vector<VB>;
using VD = vector<double>;
using VVD = vector<VD>;
using VS = vector<string>;
using PII = pair<int, int>;
using VPII = vector<PII>;
using VL = vector<long long>;
using VVL = vector<VL>;

#define sz(var) (int)var.size()
#define REP(var, start, end) for(int var = start; var < (int)end; ++var)
#define CLEAR(var, with) memset(var, with, sizeof(var))
#define ALL(x) x.begin(), x.end()
#define LL long long
#define ULL unsigned long long

int let = 0; int cnt = 1;
string generator()
{
	string ret(cnt, (char)(let + 'a'));
	ret[0] = toupper(ret[0]);
	if(let > 26)
		let = 0, ++cnt;
	++let;
	return ret;
}

int n, k;
void solve(VS& names)
{
	for(int i = 1; i <= n; ++i)
	{
		if(names[i] == "YES")
			names[i] = generator();
	}
	for(int i = 1; i + k - 1 <= n; ++i)
		if(names[i] == "NO" && names[i + k - 1] == "NO")
			names[i] = names[i + k - 1] = generator();
		else if(names[i] != "NO" && names[i + k - 1] == "NO")
			names[i + k - 1] = names[i];

	for(int i = 1; i <= n; ++i)
		if(names[i] == "NO")
			names[i] = generator();
}

int main()
{
	ios_base::sync_with_stdio(false);
	cin.tie(0);
#ifndef ONLINE_JUDGE
	freopen("tmp.in", "r", stdin);
//	freopen("tmp.out", "w", stderr);
#endif
	cin >> n >> k;
	VS names = VS(n + 1, string(1, '?'));
	string s;
	for(int i = 1; i <= n - k + 1; ++i)
	{
		cin >> s;
		if(s == "YES") {
			for(int j = i; j <= i + k - 1; ++j)
			if(names[j] == "?")
				names[j] = "YES";
		}
		else {
			for(int j = i; j <= i + k - 1; ++j)
				if(names[j] == "?")
					names[j] = "NO";
		}
	}

	solve(names);
	for(int i = 1; i <= n; ++i)
		cout << names[i] << " ";
	cout << endl;

	return 0;
}


#include <bits/stdc++.h>

using namespace std;

using VI = vector<int>;
using VVI = vector<VI>;
using VB = vector<bool>;
using VVB = vector<VB>;
using VD = vector<double>;
using VVD = vector<VD>;
using VS = vector<string>;
using PII = pair<int, int>;
using VPII = vector<PII>;
using VL = vector<long long>;
using VVL = vector<VL>;

#define sz(var) (int)var.size()
#define REP(var, start, end) for(int var = start; var < (int)end; ++var)
#define CLEAR(var, with) memset(var, with, sizeof(var))
#define ALL(x) x.begin(), x.end()
#define LL long long
#define ULL unsigned long long

int let = 0; int cnt = 1;
string generator()
{
	string ret(cnt, (char)(let + 'a'));
	ret[0] = toupper(ret[0]);
	if(let >= 25)
		let = 0, ++cnt;
	++let;
	return ret;
}

int n, k;
void solve(VS& names)
{
	for(int i = 1; i <= n; ++i)
	{
		if(names[i] == "YES")
			names[i] = generator();
	}
	for(int i = 1; i + k - 1 <= n; ++i)
		if(names[i] == "NO" && names[i + k - 1] == "NO")
			names[i] = names[i + k - 1] = generator();
		else if(names[i] != "NO" && names[i + k - 1] == "NO")
			names[i + k - 1] = names[i];

	for(int i = 1; i <= n; ++i)
		if(names[i] == "NO")
			names[i] = generator();
}

int main()
{
	ios_base::sync_with_stdio(false);
	cin.tie(0);
#ifndef ONLINE_JUDGE
	freopen("tmp.in", "r", stdin);
//	freopen("tmp.out", "w", stderr);
#endif
	cin >> n >> k;
	VS names = VS(n + 1, string(1, '?'));
	string s;
	for(int i = 1; i <= n - k + 1; ++i)
	{
		cin >> s;
		if(s == "YES") {
			for(int j = i; j <= i + k - 1; ++j)
			if(names[j] == "?")
				names[j] = "YES";
		}
		else {
			for(int j = i; j <= i + k - 1; ++j)
				if(names[j] == "?")
					names[j] = "NO";
		}
	}

	solve(names);
	for(int i = 1; i <= n; ++i)
		cout << names[i] << " ";
	cout << endl;

	return 0;
}


#include <bits/stdc++.h>

using namespace std;

using VI = vector<int>;
using VVI = vector<VI>;
using VB = vector<bool>;
using VVB = vector<VB>;
using VD = vector<double>;
using VVD = vector<VD>;
using VS = vector<string>;
using PII = pair<int, int>;
using VPII = vector<PII>;
using VL = vector<long long>;
using VVL = vector<VL>;

#define sz(var) (int)var.size()
#define REP(var, start, end) for(int var = start; var < (int)end; ++var)
#define CLEAR(var, with) memset(var, with, sizeof(var))
#define ALL(x) x.begin(), x.end()
#define LL long long
#define ULL unsigned long long

int let = 0; int cnt = 1;
string generator()
{
	string ret(cnt, (char)(let + 'a'));
	ret[0] = toupper(ret[0]);
	if(let > 26)
		let = 0, ++cnt;
	++let;
	return ret;
}

int n, k;
void solve(VS& names)
{
	for(int i = 1; i <= n; ++i)
	{
		if(names[i] == "YES")
			names[i] = generator();
	}
	for(int i = 1; i + k - 1 <= n; ++i)
		if(names[i] == "NO" && names[i + k - 1] != "NO")
			names[i] = names[i + k - 1];
		else if(names[i] != "NO" && names[i + k - 1] == "NO")
			names[i + k - 1] = names[i];
		else if(names[i] == "NO" && names[i + k - 1] == "NO")
			names[i] = names[i + k - 1] = generator();
}

int main()
{
	ios_base::sync_with_stdio(false);
	cin.tie(0);
#ifndef ONLINE_JUDGE
	freopen("tmp.in", "r", stdin);
//	freopen("tmp.out", "w", stderr);
#endif
	cin >> n >> k;
	VS names = VS(n + 1, string(1, '?'));
	string s;
	for(int i = 1; i <= n - k + 1; ++i)
	{
		cin >> s;
		if(s == "YES") {
			for(int j = i; j <= i + k - 1; ++j)
				names[j] = "YES";
		}
		else {
			for(int j = i; j <= i + k - 1; ++j)
				if(names[j] == "?")
					names[j] = "NO";
		}
	}

	solve(names);
	for(int i = 1; i <= n; ++i)
		cout << names[i] << " ";
	cout << endl;

	return 0;
}


#include<bits/stdc++.h>
using namespace std;
typedef long long ll;
int main(){
	int n , k;
	cin >> n >> k;
	string res[n] , S[n];
	for(int i = 0 ;i < n ;i ++)
		res[i] = "";
	set<string> now;
	vector< bool > vis(n);
	for(int i = 0 ;i < n - k + 1 ;i ++){
		string s ;
		cin >> s;
		if(s == "YES"){
			string ans = "A";
			for(int l = i ;l < i + k ;l ++){
				if(vis[l])continue;
				while(now.count(ans)){
					if(ans.back() != 'Z' && ans.back() != 'z'){
						char to = (ans.back() + 1);
						ans.back() = to;
					}
					else {
						ans += "a";
					}
				}
				vis[l] = 1;
				now.insert(ans);
				res[l] = ans;
			}
		}
		else {
			string ans = "A";
			for(int l = i ;l < i + k ;l ++){
				if(vis[l])continue;
				while(now.count(ans)){
					if(ans.back() != 'Z' && ans.back() != 'z'){
						char to = (ans.back() + 1);
						ans.back() = to;
					}
					else {
						ans += "a";
					}
				}
				now.insert(ans);
				res[l] = ans;
			}
			int pos = i + 1;
			while(pos < n && vis[pos])pos ++;
			assert(vis[pos] == 0);
			res[pos] = res[i];
			vis[pos] = 1;
		}
	}
	for(string r : res)
		cout << r << " ";
	cout << endl;

}


#include<bits/stdc++.h>
using namespace std;
int main(){
	int n , k;
	cin >> n >> k;
	string res[n] , S[n];
	for(int i = 0 ;i < n ;i ++)
		res[i] = "";
	set<string> now;
	vector< bool > vis(n);
	for(int i = 0 ;i < n - k + 1 ;i ++){
		string s ;
		cin >> s;
		if(s == "YES"){
			string ans = "A";
			for(int l = i ;l < i + k ;l ++){
				if(vis[l])continue;
				while(now.count(ans)){
					if(ans.back() != 'Z'){
						char to = (ans.back() + 1);
						ans.back() = to;
					}
					else {
						ans += "A";
					}
				}
				vis[l] = 1;
				now.insert(ans);
				res[l] = ans;
			}
		}
		else {
			string ans = "A";

			for(int l = i ;l < i + k ;l ++){
				if(vis[l])continue;
				while(now.count(ans)){
					if(ans.back() != 'Z'){
						char to = (ans.back() + 1);
						ans.back() = to;
					}
					else {
						ans += "A";
					}
				}
				now.insert(ans);
				res[l] = ans;
			}
			int pos = i , cnt = 0;
			while(pos < n && vis[pos] && cnt < k)pos ++ , cnt ++;
			assert(pos < n && vis[pos] == 0);
			int kk = pos;
			pos = -1;
			for(int l = i ;l < i + k ;l ++){
				if(vis[l] && pos == -1)
					pos = l;
			}
			for(int l = i ;l < i + k ;l ++){
				if(!vis[l] && pos == -1 && l != kk)
					pos = l;
			}
			if(vis[pos])res[kk] = res[pos];
			else
				res[pos] = res[kk];
			vis[pos] = vis[kk] = 1;

		}
	}
	for(string r : res)
		cout << r << " ";
	cout << endl;

}


#include<bits/stdc++.h>
using namespace std;
typedef long long ll;
int main(){
	int n , k;
	cin >> n >> k;
	string res[n] , S[n];
	for(int i = 0 ;i < n ;i ++)
		res[i] = "";
	set<string> now;
	vector< bool > vis(n);
	for(int i = 0 ;i < n - k + 1 ;i ++){
		string s ;
		cin >> s;
		if(s == "YES"){
			string ans = "A";
			for(int l = i ;l < i + k ;l ++){
				if(vis[l])continue;
				while(now.count(ans)){
					if(ans.back() != 'Z'){
						char to = (ans.back() + 1);
						ans.back() = to;
					}
					else {
						ans += "A";
					}
				}
				vis[l] = 1;
				now.insert(ans);
				res[l] = ans;
			}
		}
		else {
			string ans = "A";
			for(int l = i ;l < i + k ;l ++){
				if(vis[l])continue;
				while(now.count(ans)){
					if(ans.back() != 'Z'){
						char to = (ans.back() + 1);
						ans.back() = to;
					}
					else {
						ans += "A";
					}
				}
				now.insert(ans);
				res[l] = ans;
			}
			int pos = i + k - 1 , cnt = 0;
			while(pos < n && vis[pos] && cnt < k)pos -- , cnt ++;
			assert(vis[pos] == 0);
			res[pos] = res[i];
			vis[pos] = 1;
		}
	}
	for(string r : res)
		cout << r << " ";
	cout << endl;

}


#include<bits/stdc++.h>
using namespace std;
typedef long long ll;
int main(){
	int n , k;
	cin >> n >> k;
	string res[n] , S[n];
	for(int i = 0 ;i < n ;i ++)
		res[i] = "";
	vector< string > all;
	for(char a = 'A' ; a <= 'Z' ; a ++)
		for(char b = 'a' ; b <= 'z';  b ++)
			for(char c = 'a' ; c <= 'z' ; c ++)
				for(char d = 'a' ; d <= 'z' ; d ++)
					{
						string s = "";
						s += a;
						s += b;
						s += c;
						s += d;
						all.push_back(s);
					}
	int idx = 0;
	vector< bool > vis(n);
	for(int i = 0 ;i < n - k + 1 ;i ++){
		string s ;
		cin >> s;
		if(s == "YES"){
			string ans = "A";
			for(int l = i ;l < i + k ;l ++){
				if(vis[l])continue;
				vis[l] = 1;
				res[l] = all[idx ++];
			}
		}
		else {
			string ans = "A";
			for(int l = i ;l < i + k ;l ++){
				if(vis[l])continue;
				res[l] = all[idx ++];
			}
			int pos = i + 1;
			while(pos < n && vis[pos])pos ++;
			assert(vis[pos] == 0);
			res[pos] = res[i];
			vis[pos] = 1;
		}
	}
	for(string r : res)
		cout << r << " ";
	cout << endl;

}


#include<bits/stdc++.h>
using namespace std;
int main(){
	int n , k;
	cin >> n >> k;
	string res[n] , S[n];
	for(int i = 0 ;i < n ;i ++)
		res[i] = "";
	set<string> now;
	vector< bool > vis(n);
	for(int i = 0 ;i < n - k + 1 ;i ++){
		string s ;
		cin >> s;
		if(s == "YES"){
			string ans = "A";
			for(int l = i ;l < i + k ;l ++){
				if(vis[l])continue;
				while(now.count(ans)){
					if(ans.back() != 'Z'){
						char to = (ans.back() + 1);
						ans.back() = to;
					}
					else {
						ans += "A";
					}
				}
				vis[l] = 1;
				now.insert(ans);
				res[l] = ans;
			}
		}
		else {
			string ans = "A";

			for(int l = i ;l < i + k ;l ++){
				if(vis[l])continue;
				while(now.count(ans)){
					if(ans.back() != 'Z'){
						char to = (ans.back() + 1);
						ans.back() = to;
					}
					else {
						ans += "A";
					}
				}
				now.insert(ans);
				res[l] = ans;
			}
			int pos = i , cnt = 0;
			while(pos < n && vis[pos] && cnt < k)pos ++ , cnt ++;
			assert(pos < n && vis[pos] == 0);
			int kk = pos;
			pos = -1;
			for(int l = i + k - 1 ;l >= i ;l --){
				if(vis[l] && pos == -1)
					pos = l;
				if(!vis[l] && pos == -1 && l != kk)
					pos = l;
			}
			for(int l = i ;l < i + k ;l ++){
				if(!vis[l] && pos == -1 && l != kk)
					pos = l;
			}
			if(vis[pos])res[kk] = res[pos];
			else
				res[pos] = res[kk];
			vis[pos] = vis[kk] = 1;

		}
	}
	for(string r : res)
		cout << r << " ";
	cout << endl;

}


#include<bits/stdc++.h>
using namespace std;
typedef long long ll;
int main(){
	int n , k;
	cin >> n >> k;
	string res[n] , S[n];
	for(int i = 0 ;i < n ;i ++)
		res[i] = "";
	set<string> now;
	vector< bool > vis(n);
	for(int i = 0 ;i < n - k + 1 ;i ++){
		string s ;
		cin >> s;
		if(s == "YES"){
			string ans = "A";
			for(int l = i ;l < i + k ;l ++){
				if(vis[l])continue;
				while(now.count(ans)){
					if(ans.back() != 'Z'){
						char to = (ans.back() + 1);
						ans.back() = to;
					}
					else {
						ans += "A";
					}
				}
				vis[l] = 1;
				now.insert(ans);
				res[l] = ans;
			}
		}
		else {
			string ans = "A";
			for(int l = i ;l < i + k ;l ++){
				if(vis[l])continue;
				while(now.count(ans)){
					if(ans.back() != 'Z'){
						char to = (ans.back() + 1);
						ans.back() = to;
					}
					else {
						ans += "A";
					}
				}
				now.insert(ans);
				res[l] = ans;
			}
			int pos = i + 1;
			while(pos < n && vis[pos])pos ++;
			assert(vis[pos] == 0);
			res[pos] = res[i];
			vis[pos] = 1;
		}
	}
	for(string r : res)
		cout << r << " ";
	cout << endl;

}


#include<bits/stdc++.h>
using namespace std;
typedef long long ll;
int main(){
	int n , k;
	cin >> n >> k;
	string res[n] , S[n];
	for(int i = 0 ;i < n ;i ++)
		res[i] = "";
	set<string> now;
	vector< bool > vis(n);
	for(int i = 0 ;i < n - k + 1 ;i ++){
		string s ;
		cin >> s;
		if(s == "YES"){
			string ans = "A";
			for(int l = i ;l < i + k ;l ++){
				if(vis[l])continue;
				while(now.count(ans)){
					if(ans.back() != 'Z'){
						char to = (ans.back() + 1);
						ans.back() = to;
					}
					else {
						ans += "A";
					}
				}
				vis[l] = 1;
				now.insert(ans);
				res[l] = ans;
			}
		}
		else {
			string ans = "A";
			for(int l = i ;l < i + k ;l ++){
				if(vis[l])continue;
				while(now.count(ans)){
					if(ans.back() != 'Z'){
						char to = (ans.back() + 1);
						ans.back() = to;
					}
					else {
						ans += "A";
					}
				}
				now.insert(ans);
				res[l] = ans;
			}
			int pos = i + 1;
			while(pos < n && vis[pos])pos ++;
			assert(vis[pos] == 0);
			res[pos] = res[i];
			vis[i + 1] = 1;
		}
	}
	for(string r : res)
		cout << r << " ";
	cout << endl;

}


#include<bits/stdc++.h>
using namespace std;
typedef long long ll;
int main(){
	int n , k;
	cin >> n >> k;
	string res[n] , S[n];
	for(int i = 0 ;i < n ;i ++)
		res[i] = "";
	vector< string > all;
	for(char a = 'A' ; a <= 'Z' ; a ++)
		for(char b = 'a' ; b <= 'z';  b ++)
			for(char c = 'a' ; c <= 'z' ; c ++)
				for(char d = 'a' ; d <= 'z' ; d ++)
					for(char e = 'a'; e <= 'z' ; e ++){
						string s = "";
						s += a;
						s += b;
						s += c;
						s += d;
						s += e;
						all.push_back(s);
					}
	int idx = 0;
	vector< bool > vis(n);
	for(int i = 0 ;i < n - k + 1 ;i ++){
		string s ;
		cin >> s;
		if(s == "YES"){
			string ans = "A";
			for(int l = i ;l < i + k ;l ++){
				if(vis[l])continue;
				vis[l] = 1;
				res[l] = all[idx ++];
			}
		}
		else {
			string ans = "A";
			for(int l = i ;l < i + k ;l ++){
				if(vis[l])continue;
				res[l] = all[idx ++];
			}
			int pos = i + 1;
			while(pos < n && vis[pos])pos ++;
			assert(vis[pos] == 0);
			res[pos] = res[i];
			vis[pos] = 1;
		}
	}
	for(string r : res)
		cout << r << " ";
	cout << endl;

}


#include<bits/stdc++.h>
using namespace std;
typedef long long ll;
int main(){
	int n , k;
	cin >> n >> k;
	string res[n] , S[n];
	for(int i = 0 ;i < n ;i ++)
		res[i] = "";
	set<string> now;
	vector< bool > vis(n);
	for(int i = 0 ;i < n - k + 1 ;i ++){
		string s ;
		cin >> s;
		if(s == "YES"){
			string ans = "A";
			for(int l = i ;l < i + k ;l ++){
				if(vis[l])continue;
				while(now.count(ans)){
					if(ans.back() != 'Z' && ans.back() != 'z'){
						char to = (ans.back() + 1);
						ans.back() = to;
					}
					else {
						ans += "A";
					}
				}
				vis[l] = 1;
				now.insert(ans);
				res[l] = ans;
			}
		}
		else {
			string ans = "A";
			for(int l = i ;l < i + k ;l ++){
				if(vis[l])continue;
				while(now.count(ans)){
					if(ans.back() != 'Z' && ans.back() != 'z'){
						char to = (ans.back() + 1);
						ans.back() = to;
					}
					else {
						ans += "a";
					}
				}
				now.insert(ans);
				res[l] = ans;
			}
			int pos = i + 1;
			while(pos < n && vis[pos])pos ++;
			assert(vis[pos] == 0);
			res[pos] = res[i];
			vis[pos] = 1;
		}
	}
	for(string r : res)
		cout << r << " ";
	cout << endl;

}


#include <bits/stdc++.h>
# define ll long long
# define se second
# define fr first
using namespace std;
string ans[10010] , an[10010] , s[1000];
map<string , int> us;

int main()
{
    ll n , m , i , j , l = 1;
    cin>> n>> m;
    for(i = 1 ; i <= n - m + 1 ; i ++) cin>> s[i];
    for(i = 1 ; i < 26 ; i ++) an[i] = an[i] + char(i - 1 + 'A');
    for(i = 26 ; i <= 51 ; i ++) an[i] = an[i] + 'A' + char(i - 26 + 'a');
   // for(i = 1 ; i <= 52 ; i ++) cout << an[i]<<' ';return 0;
    l = 1;
    for(i = 1 ; i <= n ; i ++) ans[i] = an[i];
    for(i = 1 ; i <= n - m + 1 ; i ++){
        if(s[i] == "NO")
            ans[i + m - 1] = ans[i];
    }
    for(i  = 1 ; i <= n ; i ++) cout << ans[i]<<' ';
    return 0;

}


#include <bits/stdc++.h>
# define ll long long
# define se second
# define fr first
using namespace std;
string ans[10010] , an[10010] , s[1000];

int main()
{
    ll n , m , i , j , l = 1;
    cin>> n>> m;
    for(i = 1 ; i <= n - m + 1 ; i ++) cin>> s[i];
    for(i = 1 ; i <= 26 ; i ++) an[i] = an[i] + char(i + 'A');
    for(i = 27 ; i <= 52 ; i ++) an[i] = an[i] + 'A' + char(i - 27 + 'a');
    l = 1;
    for(i = 1 ; i <= n ; i ++){
        if(s[i] == "YES"){
            for(j = i ; j <= i + m - 1 ; j ++)
                if(ans[j] == "") ans[j] = an[l] , l++;
        }
    }
    string str;
    for(i = 1 ; i <= n ; i ++){
        if(s[i] == "NO"){
                str = "";
            for(j = i ; j <= i + m - 1 ; j ++){
                if(ans[j] != "") str = ans[j];
            }
            if(str == "") str = an[l] , l++;
            for(j = i ; j <= i + m - 1 ; j ++){
                if(ans[j] == "") ans[j] = str;
            }
        }
    }
    for(i = 1  ; i <= n ; i ++) cout << ans[i]<<' ';
}


#include <bits/stdc++.h>
# define ll long long
# define se second
# define fr first
using namespace std;
string ans[10010] , an[10010] , s[1000];

int main()
{
    ll n , m , i , j , l = 1;
    cin>> n>> m;
    for(i = 1 ; i <= n - m + 1 ; i ++) cin>> s[i];
    for(i = 1 ; i <= 26 ; i ++) an[i] = an[i] + char(i + 'a');
    for(i = 27 ; i <= 52 ; i ++) an[i] = an[i] + 'a' + char(i - 27 + 'a');
    l = 1;
    for(i = 1 ; i <= n ; i ++){
        if(s[i] == "YES"){
            for(j = i ; j <= i + m - 1 ; j ++)
                if(ans[j] == "") ans[j] = an[l] , l++;
        }
    }
    string str;
    for(i = 1 ; i <= n ; i ++){
        if(s[i] == "NO"){
                str = "";
            for(j = i ; j <= i + m - 1 ; j ++){
                if(ans[j] != "") str = ans[j];
            }
            if(str == "") str = an[l] , l++;
            for(j = i ; j <= i + m - 1 ; j ++){
                if(ans[j] == "") ans[j] = str;
            }
        }
    }
    for(i = 1  ; i <= n ; i ++) cout << ans[i]<<' ';
}


#include <bits/stdc++.h>

using namespace std;
#define SZ(X) ((int)X.size())
#define mp make_pair
#define pb push_back
#define RALL(X) X.rbegin(),X.rend()
#define ALL(X) X.begin(),X.end()

using ll = long long ;
using ld = long double ;

int ch[60];
string opt[55];
int main()
{
    std::ios::sync_with_stdio(false), cin.tie(0), cout.tie(0); cout << fixed;
    int n, k;
    cin >> n >> k;
    for(int i = 1;i <= n - k + 1;i ++) {
        cin >> opt[i];
    }
    for(int i = 1;i <= n - k + 1;i ++) {
        if(opt[i] == "YES") {
            for(int z = 0;z < k;z ++) {
                ch[i+z] = i + z;
            }
        }
    }
    for(int i = 1;i <= n - k + 1;i ++) {
        if(opt[i] == "NO") {
            ch[i] = ch[i+k-1];
        }
    }
    for(int i = 1;i <= n - k + 1;i ++) {
        if(opt[i] == "NO") {
            ch[i] = ch[i+k-1];
        }
    }
    vector<char>tt{'a','b','c','d','e'};
    vector<string>ANS;
    ANS.push_back("Mmp");
    do {
        string tmp;
        for(auto it : tt) tmp += it;
        tmp[0] -= ('a'-'A');
        ANS.push_back(tmp);
    }while(next_permutation(ALL(tt)));
    for(int i = 1;i <= n - 1;i ++) {
        cout << ANS[ch[i]] << " ";
    }
    cout << ANS[ch[n]] << endl;
    return 0;
}


#include <bits/stdc++.h>

using namespace std;
#define SZ(X) ((int)X.size())
#define mp make_pair
#define pb push_back
#define RALL(X) X.rbegin(),X.rend()
#define ALL(X) X.begin(),X.end()

using ll = long long ;
using ld = long double ;

int ch[60];
string opt[55];
int main()
{
    std::ios::sync_with_stdio(false), cin.tie(0), cout.tie(0); cout << fixed;
    int n, k;
    cin >> n >> k;
    for(int i = 1;i <= n - k + 1;i ++) {
        cin >> opt[i];
    }
    for(int i = 1;i <= n - k + 1;i ++) {
        if(opt[i] == "YES") {
            for(int z = 0;z < k;z ++) {
                ch[i+z] = i + z;
            }
        }
    }
    for(int i = 1;i <= n - k + 1;i ++) {
        if(opt[i] == "NO") {
            ch[i] = ch[i+k-1];
        }
    }
    vector<char>tt{'a','b','c','d','e'};
    vector<string>ANS;
    ANS.push_back("Mmp");
    do {
        string tmp;
        for(auto it : tt) tmp += it;
        tmp[0] -= ('a'-'A');
        ANS.push_back(tmp);
    }while(next_permutation(ALL(tt)));
    random_shuffle(All(ANS));
    for(int i = 1;i <= n - 1;i ++) {
        cout << ANS[ch[i]] << " ";
    }
    cout << ANS[ch[n]] << endl;
    return 0;
}


#include <bits/stdc++.h>

using namespace std;
#define SZ(X) ((int)X.size())
#define mp make_pair
#define pb push_back
#define RALL(X) X.rbegin(),X.rend()
#define ALL(X) X.begin(),X.end()

using ll = long long ;
using ld = long double ;

int ch[60];
string opt[55];
int main()
{
    std::ios::sync_with_stdio(false), cin.tie(0), cout.tie(0); cout << fixed;
    int n, k;
    cin >> n >> k;
    for(int i = 1;i <= n - k + 1;i ++) {
        cin >> opt[i];
    }
    for(int i = 1;i <= n - k + 1;i ++) {
        if(opt[i] == "YES") {
            for(int z = 0;z < k;z ++) {
                ch[i+z] = i + z;
            }
        }
    }
    for(int i = 1;i <= n - k + 1;i ++) {
        if(opt[i] == "NO") {
            for(int z = 0;z < k;z ++) {
                if(ch[i+z]) {
                    ch[i] = ch[i+z];
                    break;
                }
            }
        }
    }
    vector<char>tt{'a','b','c','d','e'};
    vector<string>ANS;
    ANS.push_back("Mmp");
    do {
        string tmp;
        for(auto it : tt) tmp += it;
        tmp[0] -= ('a'-'A');
        ANS.push_back(tmp);
    }while(next_permutation(ALL(tt)));
    for(int i = 1;i <= n - 1;i ++) {
        cout << ANS[ch[i]] << " ";
    }
    cout << ANS[ch[n]] << endl;
    return 0;
}


#include <bits/stdc++.h>

using namespace std;
#define SZ(X) ((int)X.size())
#define mp make_pair
#define pb push_back
#define RALL(X) X.rbegin(),X.rend()
#define ALL(X) X.begin(),X.end()

using ll = long long ;
using ld = long double ;

int ch[60];
string opt[55];
int main()
{
    std::ios::sync_with_stdio(false), cin.tie(0), cout.tie(0); cout << fixed;
    int n, k;
    cin >> n >> k;
    for(int i = 1;i <= n - k + 1;i ++) {
        cin >> opt[i];
    }
    for(int i = 1;i <= n - k + 1;i ++) {
        if(opt[i] == "YES") {
            for(int z = 0;z < k;z ++) {
                ch[i+z] = i + z;
            }
        }
    }
    for(int i = 1;i <= n - k + 1;i ++) {
        if(opt[i] == "NO") {
            ch[i] = ch[i+k-1];
        }
    }
    vector<char>tt{'a','b','c','d','e'};
    vector<string>ANS;
    ANS.push_back("Mmp");
    do {
        string tmp;
        for(auto it : tt) tmp += it;
        tmp[0] -= ('a'-'A');
        ANS.push_back(tmp);
    }while(next_permutation(ALL(tt)));
    for(int i = 1;i <= n - 1;i ++) {
        cout << ANS[ch[i]] << " ";
    }
    cout << ANS[ch[n]] << endl;
    return 0;
}


#include <bits/stdc++.h>

using namespace std;
#define SZ(X) ((int)X.size())
#define mp make_pair
#define pb push_back
#define RALL(X) X.rbegin(),X.rend()
#define ALL(X) X.begin(),X.end()

using ll = long long ;
using ld = long double ;

int ch[60];
string opt[55];
int main()
{
    std::ios::sync_with_stdio(false), cin.tie(0), cout.tie(0); cout << fixed;
    int n, k;
    cin >> n >> k;
    for(int i = 1;i <= n - k + 1;i ++) {
        cin >> opt[i];
    }
    for(int i = 1;i <= n; i ++) ch[i] = i;
    for(int i = 1;i <= n - k + 1;i ++) {
        if(opt[i] == "NO") {
            ch[i] = ch[i + k - 1];
        }
    }
    vector<char>tt{'a','b','c','d','e'};
    vector<string>ANS;
    ANS.push_back("Mmp");
    do {
        string tmp;
        for(auto it : tt) tmp += it;
        tmp[0] -= ('a'-'A');
        ANS.push_back(tmp);
    }while(next_permutation(ALL(tt)));
    for(int i = 1;i <= n - 1;i ++) {
        cout << ANS[ch[i]] << " ";
    }
    cout << ANS[ch[n]] << endl;
    return 0;
}


#include <bits/stdc++.h>

using namespace std;
#define SZ(X) ((int)X.size())
#define mp make_pair
#define pb push_back
#define RALL(X) X.rbegin(),X.rend()
#define ALL(X) X.begin(),X.end()

using ll = long long ;
using ld = long double ;

int ch[60];
string opt[55];
int main()
{
    std::ios::sync_with_stdio(false), cin.tie(0), cout.tie(0); cout << fixed;
    int n, k;
    cin >> n >> k;
    for(int i = 1;i <= n - k + 1;i ++) {
        cin >> opt[i];
    }
    for(int i = 1;i <= n; i ++) ch[i] = i;
    for(int i = n - k +1;i >= 1;i --) {
        if(opt[i] == "NO") {
            ch[i] = ch[i + k - 1];
        }
    }
    vector<char>tt{'a','b','c','d','e'};
    vector<string>ANS;
    ANS.push_back("Mmp");
    do {
        string tmp;
        for(auto it : tt) tmp += it;
        tmp[0] -= ('a'-'A');
        ANS.push_back(tmp);
    }while(next_permutation(ALL(tt)));
    for(int i = 1;i <= n - 1;i ++) {
        cout << ANS[ch[i]] << " ";
    }
    cout << ANS[ch[n]] << endl;
    return 0;
}


#include <bits/stdc++.h>

using namespace std;
#define SZ(X) ((int)X.size())
#define mp make_pair
#define pb push_back
#define RALL(X) X.rbegin(),X.rend()
#define ALL(X) X.begin(),X.end()

using ll = long long ;
using ld = long double ;

int ch[60];
string opt[55];
int main()
{
    std::ios::sync_with_stdio(false), cin.tie(0), cout.tie(0); cout << fixed;
    int n, k;
    cin >> n >> k;
    for(int i = 1;i <= n - k + 1;i ++) {
        cin >> opt[i];
    }
    for(int i = 1;i <= n - k + 1;i ++) {
        if(opt[i] == "YES") {
            for(int z = 0;z < k;z ++) {
                ch[i+z] = i + z;
            }
        }
    }
    for(int i = 1;i <= n - k + 1;i ++) {
        if(opt[i] == "NO") {
            ch[i] = ch[i+k-1];
        }
    }
    vector<char>tt{'a','b','c','d','e'};
    vector<string>ANS;
    ANS.push_back("Mmp");
    do {
        string tmp;
        for(auto it : tt) tmp += it;
        tmp[0] -= ('a'-'A');
        ANS.push_back(tmp);
    }while(next_permutation(ALL(tt)));
    random_shuffle(ALL(ANS));
    for(int i = 1;i <= n - 1;i ++) {
        cout << ANS[ch[i]] << " ";
    }
    cout << ANS[ch[n]] << endl;
    return 0;
}


#include <bits/stdc++.h>
using namespace std;
int parent[150000+342],size[150000+342],edge[150000+342];
long long bs(long long l,long long r,long long n){
    long long mid=(l+r)/2;
    // cout<<" l  = "<<l<<" , r = "<<r<<"\n";
    // cout<<mid<<"\n";
    if(l<r){
        if(mid*mid+mid-2*n<0){
            return bs(mid+1,r,n);
        }
        else return bs(l,mid,n);
    }
    return mid;
}

int root(int n){
    while(parent[n]!=n){
        parent[n]=parent[parent[n]];
        n=parent[n];
    }
    return n;
}

void uni(int a,int b){
    int ra,rb;
    ra=root(a);
    rb=root(b);
    if(ra!=rb){
        if(size[ra]>size[rb]){
            size[ra]+=size[rb];
            edge[ra]++;
            parent[rb]=ra;
        }
        else{
            size[rb]+=size[ra];
            edge[rb]++;
            parent[ra]=rb;
        }
    }
    else{
        edge[ra]++;
    }
}

int main()
{
    ios::sync_with_stdio(false);
    int n,k;
    string str[56];
    string name[]={"Avigujjar","Dhinchak","Enrique","Yankee","Eminem","F","G","H","I","J","K","L","M","N","O","P","Q","R","S","T","U","V","W","X","Y","Z","Aa","Ba","Ca","Da","Ea","Fa","Ga","Ha","Ia","Ja","Ka","La","Ms","Na","Oa","Pa","Qa","Ra","Sa","Ta","Ua","Va","Wa","Xa","Ya","Za"};

    cin>>n>>k;
    int index=0;
    for(int i=0;i<n-k+1;i++){
        cin>>str[i];
    }
    int smargin=INT_MAX,dmargin=INT_MAX;
    for(int i=0;i<n-k+1;i++){
        if(i==0){
            cout<<name[index]<<" ";
            if(str[i]=="YES"){
                dmargin=i+k;
                // cout<<"nigga\n";
            }
            else{
                smargin=i+k;
            }
            continue;
        }
        if(i==smargin){
            smargin=INT_MAX;
        }
        if(i==dmargin){
            dmargin=INT_MAX;
        }
        if(smargin<dmargin){
            cout<<name[index]<<" ";
        }
        else{
            cout<<name[(index+1)%51]<<" ";
            index=(index+1)%51;
        }
        if(str[i]=="YES"){
            smargin=INT_MAX;
            dmargin=i+k;
        }
        else{
            smargin=i+k;
        }
    }
    // cout<<smargin<<" , "<<dmargin<<"\n";
    for(int i=n-k+1;i<n;i++){
        if(smargin==i){
            smargin=INT_MAX;
        }
        if(dmargin==i){
            dmargin=INT_MAX;
        }
        if(smargin>dmargin){
            cout<<name[(index+1)%51]<<" ";
            index=(index+1)%51;
        }
        else{
            cout<<name[(index)]<<" ";
        }
    }
    return 0;
}


#include <bits/stdc++.h>
using namespace std;
int parent[150000+342],size[150000+342],edge[150000+342];
long long bs(long long l,long long r,long long n){
    long long mid=(l+r)/2;
    // cout<<" l  = "<<l<<" , r = "<<r<<"\n";
    // cout<<mid<<"\n";
    if(l<r){
        if(mid*mid+mid-2*n<0){
            return bs(mid+1,r,n);
        }
        else return bs(l,mid,n);
    }
    return mid;
}

int root(int n){
    while(parent[n]!=n){
        parent[n]=parent[parent[n]];
        n=parent[n];
    }
    return n;
}

void uni(int a,int b){
    int ra,rb;
    ra=root(a);
    rb=root(b);
    if(ra!=rb){
        if(size[ra]>size[rb]){
            size[ra]+=size[rb];
            edge[ra]++;
            parent[rb]=ra;
        }
        else{
            size[rb]+=size[ra];
            edge[rb]++;
            parent[ra]=rb;
        }
    }
    else{
        edge[ra]++;
    }
}

int main()
{
    ios::sync_with_stdio(false);
    int n,k;
    string str[56];
    string name[]={"Avigujjar","Dhinchak","Enriquei","Yank","Eminem","F","G","H","I","J","K","L","M","N","O","P","Q","R","S","T","U","V","W","X","Y","Z","Aa","Ba","Ca","Da","Ea","Fa","Ga","Ha","Ia","Ja","Ka","La","Ms","Na","Oa","Pa","Qa","Ra","Sa","Ta","Ua","Va","Wa","Xa","Ya","Za"};

    string res[100];
    for(int i=0;i<100;i++){
        res[i]="bokachoda";
    }
    cin>>n>>k;
    int index=0;
    for(int i=0;i<n-k+1;i++){
        cin>>str[i];
    }
    int ind=0;
    for(int i=0;i<n-k+1;i++){
        if(res[i]!="bokachoda"){
            if(str[i]=="NO"){
                res[i+k-1]=name[index];
            }
            index=(index+1)%51;
            continue;
        }
        if(name[i]=="NO"){
            res[i]=name[index];
            res[i+k-1]=name[index];
        }
        else{
            res[i]=name[index];
        }
        index=(index+1)%51;
    }
    for(int i=n-k+1;i<n;i++){
        if(res[i]!="bokachoda"){
            continue;
        }
        res[i]=name[index];
        index=(index+1)%51;
    }
    for(int i=0;i<n;i++){
        cout<<res[i]<<" ";
    }
    return 0;
}


#include <bits/stdc++.h>
using namespace std;
int parent[150000+342],size[150000+342],edge[150000+342];
long long bs(long long l,long long r,long long n){
    long long mid=(l+r)/2;
    // cout<<" l  = "<<l<<" , r = "<<r<<"\n";
    // cout<<mid<<"\n";
    if(l<r){
        if(mid*mid+mid-2*n<0){
            return bs(mid+1,r,n);
        }
        else return bs(l,mid,n);
    }
    return mid;
}

int root(int n){
    while(parent[n]!=n){
        parent[n]=parent[parent[n]];
        n=parent[n];
    }
    return n;
}

void uni(int a,int b){
    int ra,rb;
    ra=root(a);
    rb=root(b);
    if(ra!=rb){
        if(size[ra]>size[rb]){
            size[ra]+=size[rb];
            edge[ra]++;
            parent[rb]=ra;
        }
        else{
            size[rb]+=size[ra];
            edge[rb]++;
            parent[ra]=rb;
        }
    }
    else{
        edge[ra]++;
    }
}

int main()
{
    ios::sync_with_stdio(false);
    int n,k;
    string str[56];
    string name[]={"Avigujjar","Dhinchak","Enriquei","Yank","Eminem","F","G","H","I","J","K","L","M","N","O","P","Q","R","S","T","U","V","W","X","Y","Z","Aa","Ba","Ca","Da","Ea","Fa","Ga","Ha","Ia","Ja","Ka","La","Ms","Na","Oa","Pa","Qa","Ra","Sa","Ta","Ua","Va","Wa","Xa","Ya","Za"};

    string res[100];
    for(int i=0;i<100;i++){
        res[i]="bokachoda";
    }
    cin>>n>>k;
    int index=0;
    for(int i=0;i<n-k+1;i++){
        cin>>str[i];
    }
    int ind=0;
    for(int i=0;i<n-k+1;i++){
        if(res[i]!="bokachoda"){
            if(str[i]=="NO"){
                // cout<<"nigga\n";
                res[i+k-1]=res[i];
            }
            index=(index+1)%51;
            continue;
        }
        if(str[i]=="NO"){
            res[i]=name[index];
            res[i+k-1]=name[index];
        }
        else{
            res[i]=name[index];
        }
        index=(index+1)%51;
    }
    for(int i=n-k+1;i<n;i++){
        if(res[i]!="bokachoda"){
            continue;
        }
        res[i]=name[index];
        index=(index+1)%51;
    }
    for(int i=0;i<n;i++){
        cout<<res[i]<<" ";
    }
    return 0;
}


#include <bits/stdc++.h>
using namespace std;
int parent[150000+342],size[150000+342],edge[150000+342];
long long bs(long long l,long long r,long long n){
    long long mid=(l+r)/2;
    // cout<<" l  = "<<l<<" , r = "<<r<<"\n";
    // cout<<mid<<"\n";
    if(l<r){
        if(mid*mid+mid-2*n<0){
            return bs(mid+1,r,n);
        }
        else return bs(l,mid,n);
    }
    return mid;
}

int root(int n){
    while(parent[n]!=n){
        parent[n]=parent[parent[n]];
        n=parent[n];
    }
    return n;
}

void uni(int a,int b){
    int ra,rb;
    ra=root(a);
    rb=root(b);
    if(ra!=rb){
        if(size[ra]>size[rb]){
            size[ra]+=size[rb];
            edge[ra]++;
            parent[rb]=ra;
        }
        else{
            size[rb]+=size[ra];
            edge[rb]++;
            parent[ra]=rb;
        }
    }
    else{
        edge[ra]++;
    }
}

int main()
{
    ios::sync_with_stdio(false);
    int n,k;
    string str[56];
    string name[]={"Avigujjar","Dhinchakpooja","Enriqueiglesias","Daddyyankee","Eminem","F","G","H","I","J","K","L","M","N","O","P","Q","R","S","T","U","V","W","X","Y","Z","Aa","Ba","Ca","Da","Ea","Fa","Ga","Ha","Ia","Ja","Ka","La","Ms","Na","Oa","Pa","Qa","Ra","Sa","Ta","Ua","Va","Wa","Xa","Ya","Za"};

    cin>>n>>k;
    int index=0;
    for(int i=0;i<n-k+1;i++){
        cin>>str[i];
    }
    int smargin=INT_MAX,dmargin=INT_MAX;
    for(int i=0;i<n-k+1;i++){
        if(i==0){
            cout<<name[index]<<" ";
            if(str[i]=="YES"){
                dmargin=i+k;
                // cout<<"nigga\n";
            }
            else{
                smargin=i+k;
            }
            continue;
        }
        if(i==smargin){
            smargin=INT_MAX;
        }
        if(i==dmargin){
            dmargin=INT_MAX;
        }
        if(smargin<dmargin){
            cout<<name[index]<<" ";
        }
        else{
            cout<<name[(index+1)%51]<<" ";
            index=(index+1)%51;
        }
        if(str[i]=="YES"){
            smargin=INT_MAX;
            dmargin=i+k;
        }
        else{
            smargin=i+k;
        }
    }
    // cout<<smargin<<" , "<<dmargin<<"\n";
    for(int i=n-k+1;i<n;i++){
        if(smargin==i){
            smargin=INT_MAX;
        }
        if(dmargin==i){
            dmargin=INT_MAX;
        }
        if(smargin>dmargin){
            cout<<name[(index+1)%51]<<" ";
            index=(index+1)%51;
        }
        else{
            cout<<name[(index)]<<" ";
        }
    }
    return 0;
}


#include <bits/stdc++.h>
using namespace std;
int parent[150000+342],size[150000+342],edge[150000+342];
long long bs(long long l,long long r,long long n){
    long long mid=(l+r)/2;
    // cout<<" l  = "<<l<<" , r = "<<r<<"\n";
    // cout<<mid<<"\n";
    if(l<r){
        if(mid*mid+mid-2*n<0){
            return bs(mid+1,r,n);
        }
        else return bs(l,mid,n);
    }
    return mid;
}

int root(int n){
    while(parent[n]!=n){
        parent[n]=parent[parent[n]];
        n=parent[n];
    }
    return n;
}

void uni(int a,int b){
    int ra,rb;
    ra=root(a);
    rb=root(b);
    if(ra!=rb){
        if(size[ra]>size[rb]){
            size[ra]+=size[rb];
            edge[ra]++;
            parent[rb]=ra;
        }
        else{
            size[rb]+=size[ra];
            edge[rb]++;
            parent[ra]=rb;
        }
    }
    else{
        edge[ra]++;
    }
}

int main()
{
    ios::sync_with_stdio(false);
    int n,k;
    string str[56];
    string name[]={"Avigujjar","Dhinchak","Enriquei","Yank","Eminem","F","G","H","I","J","K","L","M","N","O","P","Q","R","S","T","U","V","W","X","Y","Z","Aa","Ba","Ca","Da","Ea","Fa","Ga","Ha","Ia","Ja","Ka","La","Ms","Na","Oa","Pa","Qa","Ra","Sa","Ta","Ua","Va","Wa","Xa","Ya","Za"};

    string res[100];
    for(int i=0;i<100;i++){
        res[i]="bokachoda";
    }
    cin>>n>>k;
    int index=0;
    for(int i=0;i<n-k+1;i++){
        cin>>str[i];
    }
    int ind=0;
    for(int i=0;i<n-k+1;i++){
        if(res[i]!="bokachoda"){
            if(str[i]=="NO"){
                res[i+k-1]=name[index];
            }
            index=(index+1)%51;
            continue;
        }
        if(str[i]=="NO"){
            res[i]=name[index];
            res[i+k-1]=name[index];
        }
        else{
            res[i]=name[index];
        }
        index=(index+1)%51;
    }
    for(int i=n-k+1;i<n;i++){
        if(res[i]!="bokachoda"){
            continue;
        }
        res[i]=name[index];
        index=(index+1)%51;
    }
    for(int i=0;i<n;i++){
        cout<<res[i]<<" ";
    }
    return 0;
}


#include <bits/stdc++.h>
using namespace std;
int parent[150000+342],size[150000+342],edge[150000+342];
long long bs(long long l,long long r,long long n){
    long long mid=(l+r)/2;
    // cout<<" l  = "<<l<<" , r = "<<r<<"\n";
    // cout<<mid<<"\n";
    if(l<r){
        if(mid*mid+mid-2*n<0){
            return bs(mid+1,r,n);
        }
        else return bs(l,mid,n);
    }
    return mid;
}

int root(int n){
    while(parent[n]!=n){
        parent[n]=parent[parent[n]];
        n=parent[n];
    }
    return n;
}

void uni(int a,int b){
    int ra,rb;
    ra=root(a);
    rb=root(b);
    if(ra!=rb){
        if(size[ra]>size[rb]){
            size[ra]+=size[rb];
            edge[ra]++;
            parent[rb]=ra;
        }
        else{
            size[rb]+=size[ra];
            edge[rb]++;
            parent[ra]=rb;
        }
    }
    else{
        edge[ra]++;
    }
}

int main()
{
    ios::sync_with_stdio(false);
    int n,k;
    string str[56];
    string name[]={"Avigujjar","DhinchaK","Enriquei","Yank","Eminem","F","G","H","I","J","K","L","M","N","O","P","Q","R","S","T","U","V","W","X","Y","Z","Aa","Ba","Ca","Da","Ea","Fa","Ga","Ha","Ia","Ja","Ka","La","Ms","Na","Oa","Pa","Qa","Ra","Sa","Ta","Ua","Va","Wa","Xa","Ya","Za"};

    string res[100];
    for(int i=0;i<100;i++){
        res[i]="bokachoda";
    }
    cin>>n>>k;
    int index=0;
    for(int i=0;i<n-k+1;i++){
        cin>>str[i];
    }
    int ind=0;
    for(int i=0;i<n-k+1;i++){
        if(res[i]!="bokachoda"){
            if(str[i]=="NO"){
                res[i+k-1]=name[index];
            }
            index=(index+1)%51;
            continue;
        }
        if(str[i]=="NO"){
            // cout<<"Same when i = "<<i<<" , k = "<<k<<" , i+k-1 = "<<i+k-1<<"\n";
            res[i]=name[index];
            res[i+k-1]=name[index];
        }
        else{
            res[i]=name[index];
        }
        index=(index+1)%51;
        // for(int i=0;i<n;i++){
        //     cout<<res[i]<<" ";
        // }
        // cout<<"\n";
    }
    for(int i=n-k+1;i<n;i++){
        if(res[i]!="bokachoda"){
            continue;
        }
        res[i]=name[index];
        index=(index+1)%51;
    }
    for(int i=0;i<n;i++){
        cout<<res[i]<<" ";
    }
    return 0;
}


#include <bits/stdc++.h>
using namespace std;
int parent[150000+342],size[150000+342],edge[150000+342];
long long bs(long long l,long long r,long long n){
    long long mid=(l+r)/2;
    // cout<<" l  = "<<l<<" , r = "<<r<<"\n";
    // cout<<mid<<"\n";
    if(l<r){
        if(mid*mid+mid-2*n<0){
            return bs(mid+1,r,n);
        }
        else return bs(l,mid,n);
    }
    return mid;
}

int root(int n){
    while(parent[n]!=n){
        parent[n]=parent[parent[n]];
        n=parent[n];
    }
    return n;
}

void uni(int a,int b){
    int ra,rb;
    ra=root(a);
    rb=root(b);
    if(ra!=rb){
        if(size[ra]>size[rb]){
            size[ra]+=size[rb];
            edge[ra]++;
            parent[rb]=ra;
        }
        else{
            size[rb]+=size[ra];
            edge[rb]++;
            parent[ra]=rb;
        }
    }
    else{
        edge[ra]++;
    }
}

int main()
{
    ios::sync_with_stdio(false);
    int n,k;
    string str[56];
    string name[]={"Avigujjar","DhinchaK","Enriquei","Yankee","Eminem","F","G","H","I","J","K","L","M","N","O","P","Q","R","S","T","U","V","W","X","Y","Z","Aa","Ba","Ca","Da","Ea","Fa","Ga","Ha","Ia","Ja","Ka","La","Ms","Na","Oa","Pa","Qa","Ra","Sa","Ta","Ua","Va","Wa","Xa","Ya","Za"};

    cin>>n>>k;
    int index=0;
    for(int i=0;i<n-k+1;i++){
        cin>>str[i];
    }
    int smargin=INT_MAX,dmargin=INT_MAX;
    for(int i=0;i<n-k+1;i++){
        if(i==0){
            cout<<name[index]<<" ";
            if(str[i]=="YES"){
                dmargin=i+k;
                // cout<<"nigga\n";
            }
            else{
                smargin=i+k;
            }
            continue;
        }
        if(i==smargin){
            smargin=INT_MAX;
        }
        if(i==dmargin){
            dmargin=INT_MAX;
        }
        if(smargin<dmargin){
            cout<<name[index]<<" ";
        }
        else{
            cout<<name[(index+1)%51]<<" ";
            index=(index+1)%51;
        }
        if(str[i]=="YES"){
            smargin=INT_MAX;
            dmargin=i+k;
        }
        else{
            smargin=i+k;
        }
    }
    // cout<<smargin<<" , "<<dmargin<<"\n";
    for(int i=n-k+1;i<n;i++){
        if(smargin==i){
            smargin=INT_MAX;
        }
        if(dmargin==i){
            dmargin=INT_MAX;
        }
        if(smargin>dmargin){
            cout<<name[(index+1)%51]<<" ";
            index=(index+1)%51;
        }
        else{
            cout<<name[(index)]<<" ";
        }
    }
    return 0;
}


#include<bits/stdc++.h>
#define re return
#define ll long long
#define Hossam_Yehia ios_base::sync_with_stdio(0),cin.tie(0),cout.tie(0);

using namespace std;
int n,k,last,temp;
string hh[66],out[66];
string s[100];
int main(){
    for(int i=0;i<26;++i)
        hh[i]=i+'A';
    for(int i=26;i<52;++i)
        hh[i]=i-26+'A';
    for(int i=26;i<52;i++)
        hh[i]+='a';
    cin >> n >> k;
    for(int i=0;i<=n-k;++i)
        cin >> s[i];
    if(s[0]=="YES"){
        for(int i=0;i<k;++i)
            out[i]=hh[i],last++;
    }
    for(int i=1;i<=n-k;++i){
        if(s[i]=="YES"){
            if(s[i-1]=="YES"){
                out[i+k-1]=hh[last];
                last++;
            }
            else{
                for(int j=i;j<i+k;++j){
                    out[j]=hh[last];
                    last++;
                }
            }
        }
    }
    for(int i=0;i<n;++i)
        if(!out[i].size())
            out[i]="*";
    int t=50;
    while(t--){
        for(int i=0;i<n;i++){
            if(out[i]=="*"&&out[i+1].size()&&out[i+1]!="*"){
                temp=k-1;
                for(int j=i;temp>=0&&j>=0;j--){
                    out[j]=out[i+1];
                }
            }
            else if(out[i+1]=="*"&&out[i].size()&&out[i]!="*"){
                temp=k-1;
                for(int j=i+1;temp>=0&&j<n;j++){
                    out[j]=out[i];
                }
            }
        }
    }
    int c=0;
    for(int i=0;i<n;++i)
        if(out[i]=="*")c++;
    if(c==n)
        for(int i=0;i<n;++i)out[i]='S';
    for(int i=0;i<n;++i)
        cout<<out[i]<<((i==n-1)?"\n":" ");
	re 0;
}


#include<bits/stdc++.h>
#define re return
#define ll long long
#define Hossam_Yehia ios_base::sync_with_stdio(0),cin.tie(0),cout.tie(0);

using namespace std;
int n,k,last,temp;
string hh[66],out[66];
string s[100];
int main(){
    for(int i=0;i<26;++i)
        hh[i]=i+'A';
    for(int i=26;i<52;++i)
        hh[i]=i-26+'A';
    for(int i=26;i<52;i++)
        hh[i]+='a';
    cin >> n >> k;
    for(int i=0;i<=n-k;++i)
        cin >> s[i];
    if(s[0]=="YES"){
        for(int i=0;i<k;++i)
            out[i]=hh[i],last++;
    }
    for(int i=1;i<=n-k;++i){
        if(s[i]=="YES"){
            if(s[i-1]=="YES"){
                out[i+k-1]=hh[last];
                last++;
            }
            else{
                for(int j=i;j<i+k;++j){
                    out[j]=hh[last];
                    last++;
                }
            }
        }
    }
    for(int i=0;i<n;++i)
        if(!out[i].size())
            out[i]="*";
    int t=50;
    while(t--){
        for(int i=0;i<n;i++){
            if(out[i]=="*"&&out[i+1].size()&&out[i+1]!="*"){
                temp=k-1;
                for(int j=i;temp>=0&&j>=0;j--){
                    out[j]=out[i+1];
                }
            }
            else if(out[i+1]=="*"&&out[i].size()&&out[i]!="*"){
                temp=k-1;
                for(int j=i+1;temp>=0&&j<n;j++){
                    out[j]=out[i];
                }
            }
        }
    }
    int c=0;
    for(int i=0;i<n;++i)
        if(out[i]=="*")c++;
    if(c==n)
        for(int i=0;i<n;++i)out[i]='S';
    else{
        for(int i=0;i<n;++i){
            int cc=0;
            if(s[i]=="NO"){
                for(int j=i;j<i+k-1;++j){
                    cc+=(out[j]!=out[j+1]);
                }
                if(cc==k-1)
                    out[i]=out[i+1];
            }
        }
    }
    for(int i=0;i<n;++i)
        cout<<out[i]<<((i==n-1)?"\n":" ");
	re 0;
}


#include<bits/stdc++.h>
#define re return
#define ll long long
#define Hossam_Yehia ios_base::sync_with_stdio(0),cin.tie(0),cout.tie(0);

using namespace std;
int n,k,last,temp;
string hh[66],out[66];
string s[100];
map<string,bool> vis;
bool done;
int main(){
    for(int i=0;i<26;++i)
        hh[i]=i+'A';
    for(int i=26;i<52;++i)
        hh[i]=i-26+'A';
    for(int i=26;i<52;i++)
        hh[i]+='a';
    cin >> n >> k;
    for(int i=0;i<=n-k;++i)
        cin >> s[i];
    if(s[0]=="YES"){
        for(int i=0;i<k;++i)
            out[i]=hh[i],last++;
    }
    for(int i=1;i<=n-k;++i){
        if(s[i]=="YES"){
            if(done){
                out[i+k-1]=hh[last];
                vis[hh[last]]=true;
                last++;
            }
            else{
                done=true;
                for(int j=i;j<i+k;++j){
                    out[j]=hh[last];
                    vis[hh[last]]=true;
                    last++;
                }
            }
            //if(s[i-1]=="YES"){

           // }
            /*else{

            }*/
        }
    }
    for(int i=0;i<n;++i)
        if(!out[i].size())
            out[i]="*";
    int t=60;
    while(t--){
        for(int i=0;i<n;++i){
            int cc=0;
            if(s[i]=="NO"){
                if(i&&s[i-1]=="NO"||!i)
                    out[i]=out[i+1];
                else
                    out[i+k-1]=out[i];
            }
        }
    }
    int c=0;
    for(int i=0;i<n;++i)
        if(out[i]=="*")c++;
    if(c==n)
        for(int i=0;i<n;++i)out[i]='S';
    for(int i=0;i<n;++i){
        if(out[i]=="*"){
            for(int j=0;j<52;++j)
                if(!vis[hh[j]]){
                    out[i]=hh[j];
                    vis[hh[j]]=true;
                    break;
                }
        }
    }
    // lw anta NO 7ot nfsk b ely b3dk bs kda :3
    for(int i=0;i<n;++i)
        cout<<out[i]<<((i==n-1)?"\n":" ");
	re 0;
}


#include<bits/stdc++.h>
#define re return
#define ll long long
#define Hossam_Yehia ios_base::sync_with_stdio(0),cin.tie(0),cout.tie(0);

using namespace std;
int n,k,last,temp;
string hh[66],out[66];
string s[100];
int main(){
    for(int i=0;i<26;++i)
        hh[i]=i+'A';
    for(int i=26;i<52;++i)
        hh[i]=i-26+'A';
    for(int i=26;i<52;i++)
        hh[i]+='a';
    cin >> n >> k;
    for(int i=0;i<=n-k;++i)
        cin >> s[i];
    for(int i=0;i<n;++i)
        out[i]=hh[i];
    for(int i=0;i<=n-k;++i)
        if(s[i]=="NO")out[i+k-1]=out[i];
    for(int i=0;i<n;++i)
        cout<<out[i]<<((i==n-1)?"\n":" ");
	re 0;
}


#include<bits/stdc++.h>
#define re return
#define ll long long
#define Hossam_Yehia ios_base::sync_with_stdio(0),cin.tie(0),cout.tie(0);

using namespace std;
int n,k,last,temp;
string hh[66],out[66];
string s[100];
int main(){
    for(int i=0;i<26;++i)
        hh[i]=i+'A';
    for(int i=26;i<52;++i)
        hh[i]=i+'A';
    for(int i=26;i<52;i++)
        hh[i]+='a';
    cin >> n >> k;
    for(int i=0;i<=n-k;++i)
        cin >> s[i];
    if(s[0]=="YES"){
        for(int i=0;i<k;++i)
            out[i]=hh[i],last++;
    }
    for(int i=1;i<=n-k;++i){
        if(s[i]=="YES"){
            if(s[i-1]=="YES"){
                out[i+k-1]=hh[last];
                last++;
            }
            else{
                for(int j=i;j<i+k;++j){
                    out[j]=hh[last];
                    last++;
                }
            }
        }
    }
    for(int i=0;i<n;++i)
        if(!out[i].size())
            out[i]="*";
    int t=60;
    while(t--){
        for(int i=0;i<n;i++){
            if(out[i]=="*"&&out[i+1].size()&&out[i+1]!="*"){
                temp=k-1;
                for(int j=i;temp>=0&&j>=0;j--){
                    out[j]=out[i+1];
                }
            }
            else if(out[i+1]=="*"&&out[i].size()&&out[i]!="*"){
                temp=k-1;
                for(int j=i+1;temp>=0&&j<n;j++){
                    out[j]=out[i];
                }
            }
        }
    }
    int c=0;
    for(int i=0;i<n;++i)
        if(out[i]=="*")c++;
    if(c==n)
        for(int i=0;i<n;++i)out[i]='a';
    for(int i=0;i<n;++i)
        cout<<out[i]<<((i==n-1)?"\n":" ");
	re 0;
}


#include<bits/stdc++.h>
#define re return
#define ll long long
#define Hossam_Yehia ios_base::sync_with_stdio(0),cin.tie(0),cout.tie(0);

using namespace std;
int n,k,last,temp;
char hh[66],out[66];
string s[100];
int main(){
    for(int i=0;i<26;++i)
        hh[i]=i+'a';
    for(int i=26;i<52;++i)
        hh[i]=i+'A';
    cin >> n >> k;
    for(int i=0;i<=n-k;++i)
        cin >> s[i];
    if(s[0]=="YES"){
        for(int i=0;i<k;++i)
            out[i]=hh[i],last++;
    }
    for(int i=1;i<=n-k;++i){
        if(s[i]=="YES"){
            if(s[i-1]=="YES"){
                out[i+k-1]=hh[last];
                last++;
            }
            else{
                for(int j=i;j<i+k;++j){
                    out[j]=hh[last];
                    last++;
                }
            }
        }
    }
    for(int i=0;i<n;++i)
        if(!isalpha(out[i]))
            out[i]='*';
    int t=50;
    while(t--){
        for(int i=0;i<n;i++){
            if(out[i]=='*'&&isalpha(out[i+1])){
                temp=k-1;
                for(int j=i;temp>=0&&j>=0;j--){
                    out[j]=out[i+1];
                }
            }
            else if(out[i+1]=='*'&&isalpha(out[i])){
                temp=k-1;
                for(int j=i+1;temp>=0&&j<n;j++){
                    out[j]=out[i];
                }
            }
        }
    }
    int c=0;
    for(int i=0;i<n;++i)
        if(out[i]=='*')c++;
    if(c==n)
        for(int i=0;i<n;++i)out[i]='a';
    for(int i=0;i<n;++i)
        cout<<out[i]<<" ";
	re 0;
}