#include <bits/stdc++.h>
using namespace std;
const int mod = 1e9 + 7;
int dx[] = {0, 0, 1, -1};
int dy[] = {1, -1, 0, 0};
string ds = "RLDU";
const int MAX = 1e5;
void solve() {
  int n, k;
  cin >> n >> k;
  string s;
  cin >> s;
  if (k >= 1 && n == 1) {
    cout << 0 << endl;
    return;
  }
  if (k > 0 && s[0] != '1') s[0] = '1', k--;
  int i = 1;
  while (k && i < n) {
    if (s[i] == '0') {
      i++;
      continue;
    }
    s[i] = '0';
    i++;
    k--;
  }
  cout << s << endl;
}
int main() {
  ios::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);
  int t = 1;
  for (int i = (1); i < (t + 1); i++) {
    solve();
  }
}
