<image>

William really likes the cellular automaton called "Game of Life" so he decided to make his own version. For simplicity, William decided to define his cellular automaton on an array containing n cells, with each cell either being alive or dead.

Evolution of the array in William's cellular automaton occurs iteratively in the following way:

  * If the element is dead and it has exactly 1 alive neighbor in the current state of the array, then on the next iteration it will become alive. For an element at index i the neighbors would be elements with indices i - 1 and i + 1. If there is no element at that index, it is considered to be a dead neighbor. 
  * William is a humane person so all alive elements stay alive. 



Check the note section for examples of the evolution.

You are given some initial state of all elements and you need to help William find the state of the array after m iterations of evolution.

Input

Each test contains multiple test cases. The first line contains the number of test cases t (1 ≤ t ≤ 10^3). Description of the test cases follows.

The first line of each test case contains two integers n and m (2 ≤ n ≤ 10^3, 1 ≤ m ≤ 10^9), which are the total number of cells in the array and the number of iterations.

The second line of each test case contains a string of length n made up of characters "0" and "1" and defines the initial state of the array. "1" means a cell is alive and "0" means it is dead.

It is guaranteed that the sum of n over all test cases does not exceed 10^4.

Output

In each test case output a string of length n, made up of characters "0" and "1" — the state of the array after m iterations of evolution.

Example

Input


4
11 3
01000000001
10 2
0110100101
5 2
10101
3 100
000


Output


11111001111
1110111101
10101
000

Note

Sequence of iterations of evolution for the first test case 

  * 01000000001 — initial state 
  * 11100000011 — first iteration of evolution 
  * 11110000111 — second iteration of evolution 
  * 11111001111 — third iteration of evolution 



Sequence of iterations of evolution for the second test case 

  * 0110100101 — initial state 
  * 1110111101 — first iteration of evolution 
  * 1110111101 — second iteration of evolution 
#include "bits/stdc++.h"
using namespace std;

//shorthands
#define ll                long long
#define ld                long double
#define pb                push_back
#define ppb               pop_back
#define pf                push_front
#define ppf               pop_front
#define mkp               make_pair
#define fastio            ios::sync_with_stdio(0) , cin.tie(0) , cout.tie(0);
#define all(x)            (x).begin(),(x).end()
#define uniq(v)           (v).erase(unique(all(v)),(v).end())
#define fr                first
#define sc                second
#define vll               vector <ll>
#define vpll              vector < pair<ll,ll> >
#define vect(a,n)         vll a(n); rep(i,0,n) cin>>a[i];
#define rep(i,a,b)        for(ll i = a; i < b; i++)
#define PI                3.14159265358979323846


//Debug
#define printall(a) rep(i,0,a.size()) cout<<a[i]<<" "; cout<<"\n";
#define deb(x) cout << #x << "=" << x << endl
#define deb2(x, y) cout << #x << "=" << x << "," << #y << "=" << y << endl
#define deb3(x, y, z) cout << #x << "=" << x << "," << #y << "=" << y <<","<< #z << "=" << z << endl


//Constants
const int mod = (ll) 1e9 + 7 ;
const int INF = (int) 1e18 ;

//Input-Output File
void fileio(){
    #ifndef ONLINE_JUDGE
    freopen("input.txt", "r", stdin) ;
    freopen("output.txt", "w", stdout) ;
    #endif
}

void solve() {
    ll n,m; cin >> n >> m;
    string s; cin >> s;
    ll k = min(n,m);
    while(k--) {

        vll idx;

        rep(i,0,n) {

            if(i-1 >= 0 && i+1 < n && s[i] == '0' && ((s[i+1] == '1' && s[i-1] == '0') || (s[i+1] == '0' && s[i-1] == '1'))) {

                idx.pb(i);
            }
            else if(i == 0 && s[i] == '0' && s[i+1] == '1') idx.pb(i);
            else if(i == n-1 && s[i] == '0' && s[i-1] == '1') idx.pb(i);

        }

        rep(i,0,idx.size()) {
            s[idx[i]] = '1';

        }
    }

    cout << s << "\n";
}

int main() {
    fastio;
    fileio;
    int t = 1; cin >> t;
    while(t--) solve();
}




