#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, k;
  cin >> n >> k;
  string s;
  cin >> s;
  int i = 0, j = 0;
  while (i < k && j < n) {
    if (j == 0 && n != 1) {
      if (s[j] == '1')
        j++;
      else {
        s[j] = '1';
        j++;
        i++;
      }
    } else {
      if (s[j] == '0')
        j++;
      else {
        s[j] = '0';
        j++;
        i++;
      }
    }
  }
  cout << s;
}
