#include <bits/stdc++.h>
using namespace std;
template <class T>
T big(T a, T b) {
  return a > b ? a : b;
}
long long gcd(long long a, long long b) {
  if (a == 0) return b;
  return gcd(b % a, a);
}
long long lcm(long long a, long long b) { return (a * b) / gcd(a, b); }
bool mod(long double a, long double b) { return a / b - floor(a / b); }
long long occurs(vector<long long> v, long long n) {
  auto it = lower_bound(((v)).begin(), ((v)).end(), (n));
  auto it1 = upper_bound(((v)).begin(), ((v)).end(), (n));
  long long x = it1 - it;
  return x;
}
long long logb(long long base, long long x) { return (log(x) / log(base)); }
long long pow(long long n, long long m) {
  long long ans = 1;
  for (long long i{0}; i < m; i++) {
    ans *= n;
  }
  return ans;
}
long long factors(long long ans) {
  long long count = 0;
  for (long long i = 1; i <= sqrt(ans); i++) {
    if (ans % i == 0) {
      if (ans / i == i)
        count++;
      else
        count += 2;
    }
  }
  return count;
}
bool isSubSequence(string str1, string str2, long long m, long long n) {
  if (m == 0) return true;
  if (n == 0) return false;
  if (str1[m - 1] == str2[n - 1])
    return isSubSequence(str1, str2, m - 1, n - 1);
  return isSubSequence(str1, str2, m, n - 1);
}
long long log2(long long n) {
  long long count = 0;
  while (n != 0) {
    n /= 2;
    count++;
  }
  return count - 1;
}
signed main() {
  ios_base::sync_with_stdio(false);
  cin.tie(0);
  cout.tie(0);
  long long n, m;
  cin >> n >> m;
  string s;
  cin >> s;
  if (n == 1 && m != 0) {
    cout << 0;
    return 0;
  }
  if (m == 0) {
    for (long long i{0}; i < n; i++) {
      cout << s[i];
    }
    return 0;
  }
  if (s[0] == '1') {
    m++;
  }
  cout << 1;
  for (long long i{1}; i < m; i++) {
    if (s[i] == '0') {
      m++;
    }
    cout << 0;
    if (i == n - 1) break;
  }
  if (m <= n) {
    for (long long i{m}; i < n; i++) {
      cout << s[i];
    }
  }
  return 0;
}
