#include <bits/stdc++.h>
using namespace std;
using ll = long long;
using ull = unsigned long long;
using ld = long double;
const ll INF = 1e18;
const int MOD = 1e9 + 7;
const int MX = 2e5 + 7;
const double PI = 3.1415926535897932384626;
template <class T>
void dbg(T val) {
  cout << val << '\n';
}
template <class T>
void dbgs(T val) {
  cout << val << " ";
}
void solve() {
  int n, k;
  cin >> n >> k;
  string S;
  cin >> S;
  if (k == 0) {
    dbg(S);
    return;
  }
  if (n == 1)
    dbg(0);
  else {
    if (S[0] == '1') {
      int i = 1;
      k -= 1;
      while (i < n and k >= 0) {
        if (S[i] == '0')
          i++;
        else {
          S[i] = '0';
          i++;
          k--;
        }
      }
      dbg(S);
    } else {
      S[0] = '1';
      int i = 1;
      k -= 1;
      while (i < n and k > 0) {
        if (S[i] == '0')
          i++;
        else {
          S[i] = '0';
          i++;
          k--;
        }
      }
      dbg(S);
    }
  }
}
void fastIO(string name = "") {
  cin.tie(0)->sync_with_stdio(0);
  if (int(name.size())) {
    freopen((name + ".in").c_str(), "r", stdin);
    freopen((name + ".out").c_str(), "w", stdout);
  }
}
int main() {
  fastIO("");
  int tc = 1;
  while (tc--) solve();
  return 0;
}
