Problem: Ashish has two strings a and b, each of length n, and an integer k. The strings only contain lowercase English letters.

He wants to convert string a into string b by performing some (possibly zero) operations on a.

In one move, he can either 

  * choose an index i (1 ≤ i≤ n-1) and swap a_i and a_{i+1}, or 
  * choose an index i (1 ≤ i ≤ n-k+1) and if a_i, a_{i+1}, …, a_{i+k-1} are all equal to some character c (c ≠ 'z'), replace each one with the next character (c+1), that is, 'a' is replaced by 'b', 'b' is replaced by 'c' and so on. 



Note that he can perform any number of operations, and the operations can only be performed on string a. 

Help Ashish determine if it is possible to convert string a into b after performing some (possibly zero) operations on it.

Input

The first line contains a single integer t (1 ≤ t ≤ 10^5) — the number of test cases. The description of each test case is as follows.

The first line of each test case contains two integers n (2 ≤ n ≤ 10^6) and k (1 ≤ k ≤ n).

The second line of each test case contains the string a of length n consisting of lowercase English letters.

The third line of each test case contains the string b of length n consisting of lowercase English letters.

It is guaranteed that the sum of values n among all test cases does not exceed 10^6.

Output

For each test case, print "Yes" if Ashish can convert a into b after some moves, else print "No".

You may print the letters of the answer in any case (upper or lower).

Example

Input


4
3 3
abc
bcd
4 2
abba
azza
2 1
zz
aa
6 2
aaabba
ddddcc


Output


No
Yes
No
Yes

Note

In the first test case it can be shown that it is impossible to convert a into b.

In the second test case,

"abba" \xrightarrow{inc} "acca" \xrightarrow{inc} … \xrightarrow{inc} "azza".

Here "swap" denotes an operation of the first type, and "inc" denotes an operation of the second type.

In the fourth test case,

"aaabba" \xrightarrow{swap} "aaabab" \xrightarrow{swap} "aaaabb" \xrightarrow{inc} … \xrightarrow{inc} "ddaabb" \xrightarrow{inc} … \xrightarrow{inc} "ddddbb" \xrightarrow{inc} … \xrightarrow{inc} "ddddcc".

Solution (in CPP):

Solution:
#include <bits/stdc++.h>
// #include <ext/pb_ds/assoc_container.hpp>

using namespace std;
// using namespace __gnu_pbds;

#pragma region
typedef long long ll;
typedef string str;
typedef double db;
template<typename T>using heapmax = priority_queue<T>;
template<typename T>using heapmin = priority_queue<T, vector<T>, greater<T>>;

template<typename T>void maximize(T &a, T b) { if (a < b) a = b; }
template<typename T>void minimize(T &a, T b) { if (a > b) a = b; }
template<typename T>T sqr(T a) { return a*a; }
template<typename T>T gcd(T a, T b) { while (b != 0) swap(b, a %= b); return a; }
template<typename T>T lcm(T a, T b) { return a/gcd(a, b)*b; }
template<typename T>T pw(T a, T n) { if (n == 1) return a; T t = pw(a, n/2); return (n & 1) ? t*t*a : t*t + 1; }
template<typename T>ll htoi(T x) { return 9 * (x >> 6) + (x & 017); }

template<typename T>void gstr(T& s) { char c; while (c = getchar(), c == ' ' || c == '\n' || c == '\t'); s.clear(); s.push_back(c); while (c = getchar(), c != EOF && c != ' ' && c != '\n' && c != '\t') s.push_back(c); }
template<typename T>void gline(T& s) { char c; while (c = getchar(), c == '\n'); s.clear(); s.push_back(c); while (c = getchar(), c != EOF && c != '\n') s.push_back(c); }
template<typename T>inline void gN(T& n) { char c; while (c = getchar(), c != '-' && (c < '0' || c > '9')); bool sign(c == '-'); if (sign) c = getchar(); n = c - '0'; while (c = getchar(), c >= '0' && c <= '9' ) n = 10*n + c - '0'; if (sign) n = -n; }
ll    gll() { ll x;     return        cin >> x, x; }
int     gint() { int x; return        cin >> x, x; }
str  gstr() { str x; return        cin >> x, x; }
str gline() { str x; return getline(cin, x), x; }

vector<str> split(const str& s, char c) { vector<str> v; stringstream ss(s); str x; while (getline(ss, x, c)) v.emplace_back(x); return move(v); }
template<typename T, typename... Args> inline str arrStr(T arr, int n) { stringstream s; s << "["; for(int i = 0; i < n - 1; i++) s << arr[i] << ","; s << arr[n - 1] << "]"; return s.str(); }
#define EVARS(args...) {__evars_begin(__LINE__); __evars(split(#args, ',').begin(), args);}
inline void __evars_begin(int line) { cerr << "#" << line << ": "; }
template<typename T> inline void __evars_out_var(vector<T> val) { cerr << arrStr(val, val.size()); }
template<typename T> inline void __evars_out_var(T* val) { cerr << arrStr(val, 10); }
template<typename T> inline void __evars_out_var(T val) { cerr << val; }
inline void __evars(vector<str>::iterator it) { cerr << endl; }
template<typename T, typename... Args> inline void __evars(vector<str>::iterator it, T a, Args... args) { cerr << it->substr((*it)[0] == ' ', it->length()) << "="; __evars_out_var(a); cerr << "; "; __evars(++it, args...); }

mt19937 rng(chrono::steady_clock::now().time_since_epoch().count());
struct custom_hash {
    static uint64_t splitmix64(uint64_t x) { x += 0x9e3779b97f4a7c15; x = (x ^ (x >> 30)) * 0xbf58476d1ce4e5b9; x = (x ^ (x >> 27)) * 0x94d049bb133111eb; return x ^ (x >> 31); }
    size_t operator()(uint64_t x) const { return splitmix64(x + rng()); }
};
#pragma endregion



const int     MAX  = 2e9;
const ll     LMAX = 9e18;
const int    MOD  = 1e9 + 7;
const double PI   = acos(-1);



const int N = 1e6;

int n, k;
string a, b;

pair<int, int> aa[N], bb[N];

int m1, m2, cnt;



void query() {
    cin >> n >> k;
    cin >> a >> b;
    sort(a.begin(), a.end());
    sort(b.begin(), b.end());
    

    m1 = 0, cnt = 1;
    for (int i = 1; i < n; ++i) {
        if (cnt != k && a[i] == a[i - 1]) ++cnt;
        else aa[m1++] = make_pair(cnt, a[i - 1]), cnt = 1;
    }
    aa[m1++] = make_pair(cnt, a[n - 1]);
    m2 = 0, cnt = 1;
    for (int i = 1; i < n; ++i) {
        if (cnt != k && b[i] == b[i - 1]) ++cnt;
        else bb[m2++] = make_pair(cnt, b[i - 1]), cnt = 1;
    }
    bb[m2++] = make_pair(cnt, b[n - 1]);
    if (m1 != m2) {
        cout << "NO\n";
        return;
    }
    sort (aa, aa + m1);
    sort (bb, bb + m2);


    for (int i = 0; i < m1; ++i) {
        if (aa[i].first == bb[i].first && (aa[i].second == bb[i].second || (aa[i].second < bb[i].second && aa[i].first == k)))
            continue;
        cout << "NO\n";
        return;
    }
    cout << "YES\n";
}



int main() {
#ifdef LOCAL
    freopen("m.INP", "r", stdin);
    freopen("m.OUT", "w", stdout);
#endif
    cin.tie(NULL)->sync_with_stdio(false);
    cout << fixed << setprecision(0);
    for (int t = gint(); t--; query());

    return 0;
}



/*

-----------------
input:          |

-----------------
output:            |

-----------------

*/