Problem: A palindrome is a string that reads the same backward as forward. For example, the strings "z", "aaa", "aba", and "abccba" are palindromes, but "codeforces" and "ab" are not. You hate palindromes because they give you déjà vu.

There is a string s. You must insert exactly one character 'a' somewhere in s. If it is possible to create a string that is not a palindrome, you should find one example. Otherwise, you should report that it is impossible.

For example, suppose s= "cbabc". By inserting an 'a', you can create "acbabc", "cababc", "cbaabc", "cbabac", or "cbabca". However "cbaabc" is a palindrome, so you must output one of the other options.

Input

The first line contains a single integer t (1≤ t≤ 10^4) — the number of test cases.

The only line of each test case contains a string s consisting of lowercase English letters.

The total length of all strings does not exceed 3⋅ 10^5.

Output

For each test case, if there is no solution, output "NO".

Otherwise, output "YES" followed by your constructed string of length |s|+1 on the next line. If there are multiple solutions, you may print any.

You can print each letter of "YES" and "NO" in any case (upper or lower).

Example

Input


6
cbabc
ab
zza
ba
a
nutforajaroftuna


Output


YES
cbabac
YES
aab
YES
zaza
YES
baa
NO
YES
nutforajarofatuna

Note

The first test case is described in the statement.

In the second test case, we can make either "aab" or "aba". But "aba" is a palindrome, so "aab" is the only correct answer.

In the third test case, "zaza" and "zzaa" are correct answers, but not "azza".

In the fourth test case, "baa" is the only correct answer.

In the fifth test case, we can only make "aa", which is a palindrome. So the answer is "NO".

In the sixth test case, "anutforajaroftuna" is a palindrome, but inserting 'a' elsewhere is valid.

Solution (in CPP):

Solution:
//                                         Author :: Rubai Mandal
//                                                   ------------        
//                           Institution :: Jalpaiguri Government Engineerng College
//                                          ----------------------------------------

#pragma GCC optimize("Ofast")
#pragma GCC target("avx,avx2,fma")
#pragma GCC optimization ("unroll-loops")
#include<bits/stdc++.h>
using namespace std;
#define ll long long
#define lli long long int
#define dd double
#define umap map<long long,long long>
#define smap map<string,ll>
#define mod 1000000007
#define vi std::vector<ll>
#define vs std::vector<string>
#define vc std::vector<char>
#define pb push_back
#define mp make_pair
#define fi first
#define se second
#define lvp vector<pair<ll,ll>>
#define dsort(a,n) sort(a,a+n,greater<int>())
#define srt(l) sort(l.begin(),l.end())
#define dsrt(p) sort(p.begin(), p.end(), greater<int>());
#define cunt(v,i) count(v.begin(), v.end(), i)
#define fr(i,a,n) for(ll i =a;i<n;i++)
#define rfr(i,n,a) for(ll i=n;i>=a;i--)
#define fio ios_base::sync_with_stdio(false); cin.tie(NULL); cout.tie(NULL);
#define tc(t) long long t;cin>>t;while(t--)
#define rr return(0);
#define fill(x,y) memset(x,y,sizeof(x))
#define pie 3.1415926535
#define inf 1000000000000000001
#define rev(t) reverse(t.begin(),t.end())
string abc="abcdefghijklmnopqrstuvwxyz";

ll gcd(ll a,ll b){if (a == 0) return b; return gcd(b%a, a);}
ll fact(ll n) {ll res = 1; for (ll z = 2; z <= n; z++) res = res * z; return res; }
ll Pow(ll a, ll b) {ll res = 1;while (b){if (b & 1)res = res * a % mod;a = a * a % mod; b >>= 1;}return res;}
ll amax(ll a[],ll n) { ll max=a[0];fr(i,0,n){if(a[i]>max)max=a[i];}return max;}
ll amin(ll a[],ll n) { ll min=inf;fr(i,0,n){if(a[i]<min)min=a[i];}return min;}

void ip(ll a[],ll n)  {fr(i,0,n) cin>>a[i];}
void op(ll a[],ll n)  {fr(i,0,n){if(i==n-1)cout<<a[i]<<endl;else cout<<a[i]<<" ";}}

bool comp(const pair<int,int> &a,  
               const pair<int,int> &b) 
{ 
       return (a.first > b.first); 
} 

ll divisor(ll x)
{
    ll cnt=0;
    for(int i=1;i<=sqrt(x);i++)
    {
        if(x%i==0)
        {
            if(i!=x/i)cnt+=2;
            else cnt+=1;
        }
    }
    return cnt;
}
string d2b(int n) 
{ 
    string t="";
    ll key=0;
    // Size of an integer is assumed to be 32 bits 
    for (int i = 31; i >= 0; i--) { 
        int k = n >> i; 
        if (k & 1) 
        {
            t+='1';
            key=1;
        }
        else
        {
           if(key)
           t+='0';
        }
    }
    return t;
}
ll b2d(string n) 
{ 
    string num = n; 
    ll dec_value = 0; 
  
    // Initializing base value to 1, i.e 2^0 
    ll base = 1; 
  
    ll len = num.length(); 
    for (ll i = len - 1; i >= 0; i--) { 
        if (num[i] == '1') 
            dec_value += base; 
        base = base * 2; 
    } 
  
    return dec_value; 
}

bool palindrome(ll le , ll ri , string s)
{
	if(ri-le <= 0) return true; 
	if(s[le] != s[ri])return false;
	return palindrome(le+1 , ri - 1 , s);
}
ll isprm(ll n) 
{
    if (n <= 1)  return 0; 
    if (n <= 3)  return 1; 
    if (n%2 == 0 || n%3 == 0) return 0; 
    for (int i=5; i*i<=n; i=i+6) 
        if (n%i == 0 || n%(i+2) == 0) 
           return 0; 
    return 1;
    
}
ll lcm(ll a, ll b)
{
    return a /gcd(a, b) * b;
}
bool psqr(long double x) 
{    
  long double sr = sqrt(x); 
  return ((sr - floor(sr)) == 0); 
} 

bool isPowerOfTwo(ll n)
{
   if(n==0)
   return false;
 
   return (ceil(log2(n)) == floor(log2(n)));
}
ll pali(string s,ll n)
{
    ll k=n/2;
    if(n%2==0)
    k--;
    fr(i,0,k+1)
    {
        if(s[i]!=s[n-1-i])
        return 0;
    }
    return 1;
}

int main()

{
    fio
    /*#ifndef ONLINE_JUDGE 
    	freopen("input.txt", "r", stdin); 
    	freopen("output.txt", "w", stdout); 
    	freopen("error.txt", "w", stderr); 
   #endif*/
    tc(t)
    {
        ll n;
        //cin>>n;
        string s;
        cin>>s;
        n=s.length();
        ll c=0,k;
        fr(i,0,n)
        {
            if(s[i]=='a')
            c++;
        }
        if(c==n)
        cout<<"NO\n";
        else
        {
            cout<<"YES\n";
            string s1=s;
            s1+="a";
            //cout<<s1<<endl;
            //cout<<pali(s1,n+1)<<endl;
            if(!pali(s1,n+1))
            {
                cout<<s<<'a'<<endl;
                continue;
            }
            s1="a";
            s1+=s;
            if(!pali(s1,n+1))
            {
                cout<<'a'<<s<<endl;
                continue;
            }
            cout<<s<<'a'<<endl;
            
        }
    }
    rr
}