// package com.company;
import java.util.*;
import java.io.*;
import java.lang.*;

public class Main{
    /*
     ** || ॐ श्री गणेशाय नमः ||
     ** @𝙖𝙪𝙩𝙝𝙤𝙧 𝙅𝙞𝙜𝙖𝙧_𝙉𝙖𝙞𝙣𝙪𝙟𝙞
     ** 𝙎𝙑𝙉𝙄𝙏-𝙎𝙐𝙍𝘼𝙏
     */
    public static void main(String args[]){
        PrintWriter out=new PrintWriter(System.out);
        InputReader in=new InputReader(System.in);
        TASK solver = new TASK();
        int t=1;
//         t = in.nextInt();
        for(int i=0;i<t;i++)
        {
            solver.solve(in,out,i);
        }
        out.close();
    }
    static class TASK {
        static int mod = 1000000000+7;
        void solve(InputReader in, PrintWriter out, int testNumber) {
         int n = in.nextInt();
         int k = in.nextInt();
         char[] s = in.next().toCharArray();
         if(n==1 && k!=0)
         {
             System.out.println(0);
             return;
         }
         for(int i=0;i<n;i++)
         {
             if(k==0)
                 break;
             if(i==0)
             {
                 if(s[i]=='1')
                 {
                     if(n==1)
                     {
                         s[i]='0';
                     }
                 }
                 else
                 {
                     s[i]='1';
                     k--;
                 }
             }
             else if(s[i]!='0')
             {
                 s[i]='0';
                 k--;
             }
         }

            System.out.println(String.valueOf(s));

        }
    }

    static class pair{
        int x;
        int y;
        pair(int x,int y)
        {
            this.x=x;
            this.y=y;
        }

    }
    static class Maths {
        static long gcd(long a, long b) {
            if (a == 0)
                return b;
            return gcd(b % a, a);
        }

        public static long lcm(long a, long b) {
            return (a * b) / gcd(a, b);
        }

        public static long factorial(int n) {
            long fact = 1;
            for (int i = 1; i <= n; i++) {
                fact *= i;
            }
            return fact;
        }
    }

    static class InputReader {
        private InputStream stream;
        private byte[] buf = new byte[1024];
        private int curChar;
        private int numChars;
        private SpaceCharFilter filter;

        public InputReader(InputStream stream) {
            this.stream = stream;
        }

        public int read() {
            if (numChars == -1)
                throw new InputMismatchException();

            if (curChar >= numChars) {
                curChar = 0;
                try {
                    numChars = stream.read(buf);
                } catch (IOException e) {
                    throw new InputMismatchException();
                }

                if (numChars <= 0)
                    return -1;
            }
            return buf[curChar++];
        }

        public String nextLine() {
            BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
            String str = "";
            try {
                str = br.readLine();
            } catch (IOException e) {
                e.printStackTrace();
            }
            return str;
        }

        public int nextInt() {
            int c = read();

            while (isSpaceChar(c))
                c = read();

            int sgn = 1;

            if (c == '-') {
                sgn = -1;
                c = read();
            }

            int res = 0;
            do {
                if (c < '0' || c > '9')
                    throw new InputMismatchException();
                res *= 10;
                res += c - '0';
                c = read();
            }
            while (!isSpaceChar(c));

            return res * sgn;
        }

        public long nextLong() {
            int c = read();
            while (isSpaceChar(c))
                c = read();
            int sgn = 1;
            if (c == '-') {
                sgn = -1;
                c = read();
            }
            long res = 0;

            do {
                if (c < '0' || c > '9')
                    throw new InputMismatchException();
                res *= 10;
                res += c - '0';
                c = read();
            }
            while (!isSpaceChar(c));
            return res * sgn;
        }

        public double nextDouble() {
            int c = read();
            while (isSpaceChar(c))
                c = read();
            int sgn = 1;
            if (c == '-') {
                sgn = -1;
                c = read();
            }
            double res = 0;
            while (!isSpaceChar(c) && c != '.') {
                if (c == 'e' || c == 'E')
                    return res * Math.pow(10, nextInt());
                if (c < '0' || c > '9')
                    throw new InputMismatchException();
                res *= 10;
                res += c - '0';
                c = read();
            }
            if (c == '.') {
                c = read();
                double m = 1;
                while (!isSpaceChar(c)) {
                    if (c == 'e' || c == 'E')
                        return res * Math.pow(10, nextInt());
                    if (c < '0' || c > '9')
                        throw new InputMismatchException();
                    m /= 10;
                    res += (c - '0') * m;
                    c = read();
                }
            }
            return res * sgn;
        }

        public String readString() {
            int c = read();
            while (isSpaceChar(c))
                c = read();
            StringBuilder res = new StringBuilder();
            do {
                res.appendCodePoint(c);
                c = read();
            }
            while (!isSpaceChar(c));

            return res.toString();
        }

        public boolean isSpaceChar(int c) {
            if (filter != null)
                return filter.isSpaceChar(c);
            return c == ' ' || c == '\n' || c == '\r' || c == '\t' || c == -1;
        }

        public String next() {
            return readString();
        }

        public interface SpaceCharFilter {
            public boolean isSpaceChar(int ch);
        }
    }
}


import java.util.Arrays;
import java.util.Scanner;

public class Main {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        StringBuilder sb = new StringBuilder();
        int n, k;
        n = sc.nextInt();

        k = sc.nextInt();
        String s;
        s = sc.next();
        if (s.length() == 1) {
            if (k > 0) {
                System.out.println(0);
            } else {
                System.out.println(s);
            }
            return;
        }
        if (s.charAt(0) == '-') {
            s = s.substring(1);
            sb.append('-');
            for (int i = 0; i < s.length(); i++) {
                if (k > 0 && s.charAt(i) != '9') {
                    sb.append('9');
                    k--;
                } else {
                    sb.append(s.charAt(i));
                }
            }
        } else {
            if (s.charAt(0) != '1' && k > 0) {
                sb.append('1');
                k--;
            } else {
                sb.append(s.charAt(0));
            }
            for (int i = 1; i < s.length(); i++) {
                if (k > 0 && s.charAt(i) != '0') {
                    sb.append('0');
                    k--;
                } else {
                    sb.append(s.charAt(i));
                }
            }
        }

        System.out.println(sb.toString());
    }
}


import java.util.Arrays;
import java.util.Scanner;

public class Main {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        StringBuilder sb = new StringBuilder();
        int n, k;
        n = sc.nextInt();
        if (n == 1) {
            System.out.println(0);
            return;
        }
        k = sc.nextInt();
        String s;
        s = sc.next();
        if (s.charAt(0) == '-') {
            s = s.substring(1);
            sb.append('-');
            for (int i = 0; i < s.length(); i++) {
                if (k > 0 && s.charAt(i) != '9') {
                    sb.append('9');
                    k--;
                } else {
                    sb.append(s.charAt(i));
                }
            }
        } else {
            if (s.charAt(0) != '1') {
                sb.append('1');
                k--;
            } else {
                sb.append(s.charAt(0));
            }
            for (int i = 1; i < s.length(); i++) {
                if (k > 0 && s.charAt(i) != '0') {
                    sb.append('0');
                    k--;
                } else {
                    sb.append(s.charAt(i));
                }
            }
        }

        System.out.println(sb.toString());
    }
}


import java.util.Arrays;
import java.util.Scanner;

public class Main {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        StringBuilder sb = new StringBuilder();
        int n, k;
        n = sc.nextInt();

        k = sc.nextInt();
        String s;
        s = sc.next();
        if (s.length() == 1) {
            if (k > 0) {
                System.out.println(0);
            } else {
                System.out.println(s);
            }
            return;
        }
        if (s.charAt(0) == '-') {
            s = s.substring(1);
            sb.append('-');
            for (int i = 0; i < s.length(); i++) {
                if (k > 0 && s.charAt(i) != '9') {
                    sb.append('9');
                    k--;
                } else {
                    sb.append(s.charAt(i));
                }
            }
        } else {
            if (s.charAt(0) != '1') {
                sb.append('1');
                k--;
            } else {
                sb.append(s.charAt(0));
            }
            for (int i = 1; i < s.length(); i++) {
                if (k > 0 && s.charAt(i) != '0') {
                    sb.append('0');
                    k--;
                } else {
                    sb.append(s.charAt(i));
                }
            }
        }

        System.out.println(sb.toString());
    }
}


import java.util.Arrays;
import java.util.Scanner;

public class Main {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        StringBuilder sb = new StringBuilder();
        int n, k;
        n = sc.nextInt();
        if (n == 1) {
            System.out.println(0);
            return;
        }
        k = sc.nextInt();
        String s;
        s = sc.next();
        if (s.charAt(0) == '-') {
            s = s.substring(1);
            sb.append('-');
        }

        if (s.charAt(0) != '1') {
            sb.append('1');
            k--;
        } else {
            sb.append(s.charAt(0));
        }
        for (int i = 1; i < s.length(); i++) {
            if (k > 0 && s.charAt(i) != '0') {
                sb.append('0');
                k--;
            } else {
                sb.append(s.charAt(i));
            }
        }

        System.out.println(sb.toString());
    }
}


import java.util.Arrays;
import java.util.Scanner;

public class Main {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        StringBuilder sb = new StringBuilder();
        int n, k;
        n = sc.nextInt();
        if (n == 1) {
            System.out.println(0);
            return;
        }
        k = sc.nextInt();
        String s;
        s = sc.next();
        if (s.charAt(0) != '1') {
            sb.append('1');
            k--;
        } else {
            sb.append(s.charAt(0));
        }
        for (int i = 1; i < s.length(); i++) {
            if (k > 0 && s.charAt(i) != '0') {
                sb.append('0');
                k--;
            } else {
                sb.append(s.charAt(i));
            }
        }
        System.out.println(sb.toString());
    }
}


import java.util.Arrays;
import java.util.Scanner;

public class Main {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        StringBuilder sb = new StringBuilder();
        int n, k;
        n = sc.nextInt();

        k = sc.nextInt();
        String s;
        s = sc.next();
        if (s.length() == 1) {
            System.out.println(0);
            return;
        }
        if (s.charAt(0) == '-') {
            s = s.substring(1);
            sb.append('-');
            for (int i = 0; i < s.length(); i++) {
                if (k > 0 && s.charAt(i) != '9') {
                    sb.append('9');
                    k--;
                } else {
                    sb.append(s.charAt(i));
                }
            }
        } else {
            if (s.charAt(0) != '1') {
                sb.append('1');
                k--;
            } else {
                sb.append(s.charAt(0));
            }
            for (int i = 1; i < s.length(); i++) {
                if (k > 0 && s.charAt(i) != '0') {
                    sb.append('0');
                    k--;
                } else {
                    sb.append(s.charAt(i));
                }
            }
        }

        System.out.println(sb.toString());
    }
}


import java.io.OutputStream;
import java.io.IOException;
import java.io.InputStream;
import java.io.OutputStream;
import java.io.PrintWriter;
import java.io.BufferedWriter;
import java.io.Writer;
import java.io.OutputStreamWriter;
import java.util.InputMismatchException;
import java.io.IOException;
import java.io.InputStream;

/**
 * Built using CHelper plug-in
 * Actual solution is at the top
 */
public class Main {
    public static void main(String[] args) {
        InputStream inputStream = System.in;
        OutputStream outputStream = System.out;
        InputReader in = new InputReader(inputStream);
        OutputWriter out = new OutputWriter(outputStream);
        BAniaAndMinimizing solver = new BAniaAndMinimizing();
        solver.solve(1, in, out);
        out.close();
    }

    static class BAniaAndMinimizing {
        public void solve(int testNumber, InputReader in, OutputWriter out) {
            int ntc = 1;
//        ntc = in.nextInt();
            while ((ntc--) > 0) {
                int n = in.nextInt();
                int k = in.nextInt();
                String s = in.nextString();
                int[] srr = new int[n];
                for (int i = 0; i < n; i++) {
                    srr[i] = s.charAt(i) - '0';
                }
                if (n == 1) {
                    if (k > 0) {
                        out.println(0);
                    } else {
                        out.println(s);
                    }
                    continue;
                }
                int fixidx = 0;
                while (k > 0 && fixidx < n) {
                    if (fixidx == 0) {
                        if (srr[fixidx] != 1) {
                            srr[0] = 1;
                            k--;
                        }
                    } else {
                        if (srr[fixidx] != 0) {
                            srr[fixidx] = 0;
                            k--;
                        }
                    }
                    fixidx++;
                }
                for (int i = 0; i < n; i++) {
                    out.print(srr[i]);
                }
                out.println();
            }
        }

    }

    static class InputReader {
        private InputStream stream;
        private byte[] buf = new byte[1024];
        private int curChar;
        private int numChars;
        private InputReader.SpaceCharFilter filter;

        public InputReader(InputStream stream) {
            this.stream = stream;
        }

        public int read() {
            if (numChars == -1) {
                throw new InputMismatchException();
            }
            if (curChar >= numChars) {
                curChar = 0;
                try {
                    numChars = stream.read(buf);
                } catch (IOException e) {
                    throw new InputMismatchException();
                }
                if (numChars <= 0) {
                    return -1;
                }
            }
            return buf[curChar++];
        }

        public int nextInt() {
            int c = read();
            while (isSpaceChar(c)) {
                c = read();
            }
            int sgn = 1;
            if (c == '-') {
                sgn = -1;
                c = read();
            }
            int res = 0;
            do {
                if (c < '0' || c > '9') {
                    throw new InputMismatchException();
                }
                res *= 10;
                res += c - '0';
                c = read();
            } while (!isSpaceChar(c));
            return res * sgn;
        }

        public String nextString() {
            int c = read();
            while (isSpaceChar(c)) {
                c = read();
            }
            StringBuilder res = new StringBuilder();
            do {
                if (Character.isValidCodePoint(c)) {
                    res.appendCodePoint(c);
                }
                c = read();
            } while (!isSpaceChar(c));
            return res.toString();
        }

        public boolean isSpaceChar(int c) {
            if (filter != null) {
                return filter.isSpaceChar(c);
            }
            return isWhitespace(c);
        }

        public static boolean isWhitespace(int c) {
            return c == ' ' || c == '\n' || c == '\r' || c == '\t' || c == -1;
        }

        public interface SpaceCharFilter {
            public boolean isSpaceChar(int ch);

        }

    }

    static class OutputWriter {
        private final PrintWriter writer;

        public OutputWriter(OutputStream outputStream) {
            writer = new PrintWriter(new BufferedWriter(new OutputStreamWriter(outputStream)));
        }

        public OutputWriter(Writer writer) {
            this.writer = new PrintWriter(writer);
        }

        public void println() {
            writer.println();
        }

        public void print(Object... objects) {
            for (int i = 0; i < objects.length; ++i) {
                if (i != 0) {
                    writer.print(' ');
                }
                writer.print(objects[i]);
            }
        }

        public void println(Object... objects) {
            print(objects);
            writer.println();
        }

        public void close() {
            writer.close();
        }

        public void println(long i) {
            writer.println(i);
        }

        public void print(int i) {
            writer.print(i);
        }

    }
}


import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.math.BigInteger;
import java.util.Scanner;
import java.util.StringTokenizer;

public class Main {

	static class FastReader
	{
	 	BufferedReader br;
	    StringTokenizer st;

	    public FastReader()
	    {
	        br = new BufferedReader(new
	                 InputStreamReader(System.in));
	    }

	    String next()
	    {
	        while (st == null || !st.hasMoreElements())
	        {
	            try
	            {
	                st = new StringTokenizer(br.readLine());
	            }
	            catch (IOException  e)
	            {
	                e.printStackTrace();
	            }
	        }
	        return st.nextToken();
	    }

	    int nextInt()
	    {
	        return Integer.parseInt(next());
	    }

	    long nextLong()
	    {
	        return Long.parseLong(next());
	    }
	}

	public static void main(String[] args) {

		FastReader sc = new FastReader();
		int n = sc.nextInt();
		int k = sc.nextInt();
		Scanner s = new Scanner(System.in);
		char[] c = s.nextBigInteger().toString().toCharArray();

		int count = 0;

		if(n ==1 && k>=1)
			System.out.println("0");

		else {
			if(c[0] != '1') {
				c[0] = '1';
				count++;
			}

			for(int i=1; i<n && count<k; i++) {
				if(c[i] != '0') {
					c[i] = '0';
					count++;
				}
			}

			System.out.println(c);
		}

		s.close();

	}

}


import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.util.StringTokenizer;

public class Main {

	static class FastReader
	{
	 	BufferedReader br;
	    StringTokenizer st;

	    public FastReader()
	    {
	        br = new BufferedReader(new
	                 InputStreamReader(System.in));
	    }

	    String next()
	    {
	        while (st == null || !st.hasMoreElements())
	        {
	            try
	            {
	                st = new StringTokenizer(br.readLine());
	            }
	            catch (IOException  e)
	            {
	                e.printStackTrace();
	            }
	        }
	        return st.nextToken();
	    }

	    int nextInt()
	    {
	        return Integer.parseInt(next());
	    }

	    long nextLong()
	    {
	        return Long.parseLong(next());
	    }
	}

	public static void main(String[] args) {

		FastReader sc = new FastReader();
		int n = sc.nextInt();
		int k = sc.nextInt();
		char[] c = Long.toString(sc.nextLong()).toCharArray();

		int count = 0;

		if(n ==1 && k>=1)
			System.out.println("0");

		else {
			if(c[0] != '1') {
				c[0] = '1';
				count++;
			}

			for(int i=1; i<n && count<k; i++) {
				if(c[i] != '0') {
					c[i] = '0';
					count++;
				}
			}

			System.out.println(c);
		}

	}

}


import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.util.StringTokenizer;

public class Main {

	static class FastReader
	{
	 	BufferedReader br;
	    StringTokenizer st;

	    public FastReader()
	    {
	        br = new BufferedReader(new
	                 InputStreamReader(System.in));
	    }

	    String next()
	    {
	        while (st == null || !st.hasMoreElements())
	        {
	            try
	            {
	                st = new StringTokenizer(br.readLine());
	            }
	            catch (IOException  e)
	            {
	                e.printStackTrace();
	            }
	        }
	        return st.nextToken();
	    }

	    int nextInt()
	    {
	        return Integer.parseInt(next());
	    }

	    long nextLong()
	    {
	        return Long.parseLong(next());
	    }
	}

	public static void main(String[] args) {

		FastReader sc = new FastReader();
		int n = sc.nextInt();
		int k = sc.nextInt();
		char[] c = Integer.toString(sc.nextInt()).toCharArray();

		int count = 0;

		if(n ==1 && k>=1)
			System.out.println("0");

		else {
			if(c[0] != '1') {
				c[0] = '1';
				count++;
			}

			for(int i=1; i<n && count<k; i++) {
				if(c[i] != '0') {
					c[i] = '0';
					count++;
				}
			}

			System.out.println(c);
		}

	}

}


import java.util.Scanner;

public class Main {

	public static void main(String[] args) {

		//FastReader sc = new FastReader();
		Scanner sc = new Scanner(System.in);
		int n = sc.nextInt();
		int k = sc.nextInt();
		sc.nextLine();
		String s = sc.nextLine();
		char[] c = s.toCharArray();

		int count = 0;
		//System.out.println(s);

		if(n ==1 && k>=1)
			System.out.println("0");

		else {
			if(c[0] != '1') {
				c[0] = '1';
				count++;
			}

			for(int i=1; i<n && count<k; i++) {
				if(c[i] != '0') {
					c[i] = '0';
					count++;
				}
			}

			System.out.println(c);
		}

		sc.close();
	}

}


import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.math.BigInteger;
import java.util.Scanner;
import java.util.StringTokenizer;

public class Main {

	/*static class FastReader
	{
	 	BufferedReader br;
	    StringTokenizer st;

	    public FastReader()
	    {
	        br = new BufferedReader(new
	                 InputStreamReader(System.in));
	    }

	    String next()
	    {
	        while (st == null || !st.hasMoreElements())
	        {
	            try
	            {
	                st = new StringTokenizer(br.readLine());
	            }
	            catch (IOException  e)
	            {
	                e.printStackTrace();
	            }
	        }
	        return st.nextToken();
	    }

	    int nextInt()
	    {
	        return Integer.parseInt(next());
	    }

	    long nextLong()
	    {
	        return Long.parseLong(next());
	    }
	}*/

	public static void main(String[] args) {

		//FastReader sc = new FastReader();
		Scanner sc = new Scanner(System.in);
		int n = sc.nextInt();
		int k = sc.nextInt();
		char[] c = sc.nextBigInteger().toString().toCharArray();

		int count = 0;

		if(n ==1 && k>=1)
			System.out.println("0");

		else {
			if(c[0] != '1') {
				c[0] = '1';
				count++;
			}

			for(int i=1; i<n && count<k; i++) {
				if(c[i] != '0') {
					c[i] = '0';
					count++;
				}
			}

			System.out.println(c);
		}

		sc.close();

	}

}


import java.util.Scanner;

public class Main {

	public static void main(String[] args) {

		//FastReader sc = new FastReader();
		Scanner sc = new Scanner(System.in);
		int n = sc.nextInt();
		int k = sc.nextInt();
		sc.nextLine();
		String s = sc.nextLine();
		char[] c = s.toCharArray();

		int count = 0;
		//System.out.println(s);

		if(n ==1 && k>=1)
			System.out.println("0");

		else {
			if(c[0] != '1' && k>0) {
				c[0] = '1';
				count++;
			}

			for(int i=1; i<n && count<k; i++) {
				if(c[i] != '0') {
					c[i] = '0';
					count++;
				}
			}

			System.out.println(c);
		}

		sc.close();
	}

}


import java.util.Scanner;
public class aniaAndMinimize {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        int k = sc.nextInt();
        String s = sc.next();
        StringBuilder ans = new StringBuilder();
        if (n == 1) {
           if(k>0)
               System.out.println("0");
           else
               System.out.println(s.charAt(0));
        } else {
            for (int i = 0; i < n; i++) {
                if (i == 0) {
                    if (s.charAt(i) != '1') {
                        if (k > 0) {
                            ans.append('1');
                            k--;
                        } else {
                            ans.append(s.substring(i));
                            break;
                        }
                    } else {
                        ans.append('1');
                    }
                } else {
                    if (s.charAt(i) != '0') {
                        if (k > 0) {
                            ans.append('0');
                            k--;
                        } else {
                            ans.append(s.substring(i));
                            break;
                        }
                    } else {
                        ans.append('0');
                    }
                }
            }
            System.out.println(ans);
        }
    }
}


import java.util.Scanner;
public class aniaAndMinimize {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        int k = sc.nextInt();
        String s = sc.next();
        String ans = "";
        if (n == 1) {
           if(k>0)
               System.out.println("0");
           else
               System.out.println(s.charAt(0));
        } else {
            for (int i = 0; i < n; i++) {
                if (i == 0) {
                    if (s.charAt(i) != '1') {
                        if (k > 0) {
                            ans += '1';
                            k--;
                        } else {
                            ans += s.charAt(i);
                            break;
                        }
                    } else {
                        ans += '1';
                    }
                } else {
                    if (s.charAt(i) != '0') {
                        if (k > 0) {
                            ans += '0';
                            k--;
                        } else {
                            ans += s.substring(i);
                            break;
                        }
                    } else {
                        ans += '0';
                    }
                }
            }
            System.out.println(ans);
        }
    }
}


import java.util.Scanner;
public class aniaAndMinimize {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        int k = sc.nextInt();
        String s = sc.next();
        StringBuilder ans = new StringBuilder();
        if (n == 1) {
           if(k>0)
               System.out.println("0");
           else
               System.out.println(s.charAt(0));
        } else {
            for (int i = 0; i < n; i++) {
                if (i == 0) {
                    if (s.charAt(i) != '1') {
                        if (k > 0) {
                            ans.append('1');
                            k--;
                        } else {
                            ans.append(s.charAt(i));
                            break;
                        }
                    } else {
                        ans.append('1');
                    }
                } else {
                    if (s.charAt(i) != '0') {
                        if (k > 0) {
                            ans.append('0');
                            k--;
                        } else {
                            ans.append(s.substring(i));
                            break;
                        }
                    } else {
                        ans.append('0');
                    }
                }
            }
            System.out.println(ans);
        }
    }
}


import java.util.*;
public class asd
{
    public static void main(String args[])
    {
        Scanner s=new Scanner(System.in);
        int n=s.nextInt();
        int k=s.nextInt();
        String str=s.next();
        char ch3[]=new char[str.length()];
        for(int i=0;i<str.length();i++)
            ch3[i]=str.charAt(i);
        if(n==1&&k>0)
            System.out.println("0");
        else
        {
        if(ch3[0]!='1'&&k>0)
        {ch3[0]='1';k--;}

           for(int i=1;i<n;i++)
           {
               if(ch3[i]!='0'&&k>0)
               {ch3[i]='0';k--;}
           }
        for(int i=0;i<n;i++)
        System.out.print(ch3[i]);
        System.out.println("\n");
    }
    }
}


import java.util.*;
public class asd
{
    public static void main(String args[])
    {
        Scanner s=new Scanner(System.in);
        int n=s.nextInt();
        int k=s.nextInt();
        String str=s.next();
        char ch3[]=new char[str.length()];
        for(int i=0;i<str.length();i++)
            ch3[i]=str.charAt(i);
        if(n==1)
            System.out.println("0");
        else
        {
        if(ch3[0]!='1')
        {ch3[0]='1';k--;}

           for(int i=1;i<n;i++)
           {
               if(ch3[i]!='0'&&k>0)
               {ch3[i]='0';k--;}
           }
        for(int i=0;i<n;i++)
        System.out.print(ch3[i]);
        System.out.println("\n");
    }
    }
}


import java.io.*;
import java.util.*;

/*
Good, better, best. Never let it rest. 'Til your good is better and your better is best.
 */

public class G {

    // SOLVER
    static void solve() {
        // INPUT OUTPUT
        InputReader in = new InputReader(System.in);
        PrintWriter pw = new PrintWriter(new BufferedWriter(new OutputStreamWriter(System.out)));

        int testCase = 1;
        StringBuilder result = new StringBuilder();
        while (--testCase >= 0)
        /**************************************************************************/ {
            // SOLVE
            int lengthOfNumbers = in.nextInt();      //n
            int maxNumberOfChangeAllowed = in.nextInt();    //k
            String theNumber = in.readString();    //S

            int[] eachDigitInNumber = new int[lengthOfNumbers];
            for (int i = 0; i < lengthOfNumbers; i++) {
                eachDigitInNumber[i] = theNumber.charAt(i) - 48;
            }

            if (maxNumberOfChangeAllowed == 0) {
                result.append(theNumber);
                pw.println(result.toString().trim());
                pw.close();
            }
            if (maxNumberOfChangeAllowed == 1 && lengthOfNumbers == 1) {
                result.append(0);
                pw.println(result.toString().trim());
                pw.close();
            }
            int id = 0; int changed = 0;
            while (changed < maxNumberOfChangeAllowed && id < lengthOfNumbers) {
                if (id == 0) {
                    if (eachDigitInNumber[id] != 1) {
                        ++changed;
                    }
                    eachDigitInNumber[id] = 1;
                } else {
                    if (eachDigitInNumber[id] != 0) {
                        ++changed;
                    }
                    eachDigitInNumber[id] = 0;
                }
                ++id;
            }

            for (int i = 0; i < lengthOfNumbers; i++) {
                result.append(eachDigitInNumber[i]);
            }
            /*****************************************/
        }
        pw.println(result.toString().trim());
        // *************************************
        {
            pw.close();
        }
    }

    /**************************************************************************
     *************************************************************************/
    // DRIVER CODE
    public static void main(String[] args) {
        solve();
    }

    /*Md. Nazrul Islam*/

    // FAST INPUT
    static class InputReader {

        private final InputStream stream;
        private final byte[] buf = new byte[8192];
        private int curChar, snumChars;
        private SpaceCharFilter filter;

        public InputReader(InputStream stream) {
            this.stream = stream;
        }

        public int snext() {
            if (snumChars == -1)
                throw new InputMismatchException();
            if (curChar >= snumChars) {
                curChar = 0;
                try {
                    snumChars = stream.read(buf);
                } catch (IOException e) {
                    throw new InputMismatchException();
                }
                if (snumChars <= 0)
                    return -1;
            }
            return buf[curChar++];
        }

        public int nextInt() {
            int c = snext();
            while (isSpaceChar(c)) {
                c = snext();
            }
            int sgn = 1;
            if (c == '-') {
                sgn = -1;
                c = snext();
            }
            int res = 0;
            do {
                if (c < '0' || c > '9')
                    throw new InputMismatchException();
                res *= 10;
                res += c - '0';
                c = snext();
            } while (!isSpaceChar(c));
            return res * sgn;
        }

        public long nextLong() {
            int c = snext();
            while (isSpaceChar(c)) {
                c = snext();
            }
            int sgn = 1;
            if (c == '-') {
                sgn = -1;
                c = snext();
            }
            long res = 0;
            do {
                if (c < '0' || c > '9')
                    throw new InputMismatchException();
                res *= 10;
                res += c - '0';
                c = snext();
            } while (!isSpaceChar(c));
            return res * sgn;
        }

        public int[] nextIntArray(int n) {
            int a[] = new int[n];
            for (int i = 0; i < n; i++) {
                a[i] = nextInt();
            }
            return a;
        }

        public long[] nextLongArray(int n) {
            long[] a = new long[n];
            for (int i = 0; i < n; i++) {
                a[i] = nextLong();
            }
            return a;
        }

        public String readString() {
            int c = snext();
            while (isSpaceChar(c)) {
                c = snext();
            }
            StringBuilder res = new StringBuilder();
            do {
                res.appendCodePoint(c);
                c = snext();
            } while (!isSpaceChar(c));
            return res.toString();
        }

        public String nextLine() {
            int c = snext();
            while (isSpaceChar(c))
                c = snext();
            StringBuilder res = new StringBuilder();
            do {
                res.appendCodePoint(c);
                c = snext();
            } while (!isEndOfLine(c));
            return res.toString();
        }

        public boolean isSpaceChar(int c) {
            if (filter != null)
                return filter.isSpaceChar(c);
            return c == ' ' || c == '\n' || c == '\r' || c == '\t' || c == -1;
        }

        private boolean isEndOfLine(int c) {
            return c == '\n' || c == '\r' || c == -1;
        }

        public interface SpaceCharFilter {
            public boolean isSpaceChar(int ch);
        }
    }
}


import java.io.BufferedReader;
import java.io.InputStreamReader;
import java.util.Scanner;

public class AniaandMinimizing {
    public static void main(String[]args) {
        Scanner s = new Scanner(new BufferedReader(new InputStreamReader(System.in)));
        int n=s.nextInt();
        int k=s.nextInt();
        String str=s.next();
        String[] num=new String[n];
        int j=0;
        int i;
        if(n==1&&k>0) {
            System.out.println(0);
            return;
        }
        for( i=0;i<str.length()&&k>0;i++){
            if(i==0&&str.charAt(i)=='1'){
                num[j]= String.valueOf(str.charAt(i));
            }
            else if(i==0&&str.charAt(i)!='1'){
                num[j]="1";
                k--;
            }
            else if(i!=0&&str.charAt(i)!='0'){
                num[j]="0";
                k--;
            }
            else{
                num[j]= String.valueOf(str.charAt(i));
            }
            j++;
        }
        while (i<str.length()){
            num[j]= String.valueOf(str.charAt(i));
            j++;
            i++;
        }
        for(int m=0;m<num.length;m++)
            System.out.print(num[m]);
    }
    }


import java.util.*;
public class xl3ster2 {

    public static void main(String[] args) {
	Scanner sc = new Scanner(System.in);
	int n = sc.nextInt(), k = sc.nextInt();
	String s = sc.next();
	sc.close();
	String[] num = s.split("");
	if (n == 1) {
	    if (k > 0) {
		System.out.println(0);
		System.exit(0);
	    }
	}
	for (int i = 0; i < n && k > 0; i++) {
	    if (i > 0) {
		if (!num[i].equals("0")) {
		    num[i] = "0";
		    k--;
		}
	    } else {
		if (!num[i].equals("1")) {
		    num[i] = "1";
		    k--;
		}
	    }
	}
	for (int i = 0; i < n; i++) {
	    System.out.print(num[i]);
	}
    }
}


import java.util.*;

public class dp21 {
    public static void main(String args[]) {
        Scanner sc = new Scanner(System.in);
        StringTokenizer str = new StringTokenizer(sc.nextLine(), " ");
        int n = Integer.parseInt(str.nextToken());
        int k = Integer.parseInt(str.nextToken());
        String s = sc.next();
        int ar[] = new int[n];
        for (int x = 0; x < n; x++) {
            ar[x] = Integer.parseInt(s.substring(x, x + 1));
        }
        boolean drag = false;
        if (ar[0] != 1 && k >= 1) {
            ar[0] = 1;
            drag = true;
        }
        int end = ((drag) ? k : (k + 1));
        if (n == 1) {
            if (k == 1)
                System.out.println(0);
            else
                System.out.println(n);
            return;
        }
        for (int i = 1; i < end; i++) {
            if (ar[i] != 0) {
                ar[i] = 0;
            }
        }
        for (int p = 0; p < n; p++) {
            System.out.print(ar[p]);
        }
        System.out.println();

    }
}


import java.util.*;

public class dp21 {
    public static void main(String args[]) {
        Scanner sc = new Scanner(System.in);
        StringTokenizer str = new StringTokenizer(sc.nextLine(), " ");
        int n = Integer.parseInt(str.nextToken());
        int k = Integer.parseInt(str.nextToken());
        String s = sc.next();
        if (n == 1) {
            if (k == 1)
                System.out.println(0);
            else
                System.out.println(n);
            return;
        }
        int i = 0;
        int l = s.length();
        String w = "";
        while (i < l && k > 0) {
            char ch = s.charAt(i);
            if (i == 0 && ch != '1') {
                w = w + 1;
                k--;
            } else if (i == 0 && ch == '1') {
                w = w + 1;
            }
            if (i != 0) {
                if (ch != '0') {
                    w = w + 0;
                    k--;
                } else {
                    w = w + 0;
                }
            }
            i++;
        }
        System.out.print(w);
        for (int p = i; p < l; p++) {
            System.out.print(s.charAt(p));
        }
        System.out.println();

    }
}


import java.util.*;

public class dp21 {
    public static void main(String args[]) {
        Scanner sc = new Scanner(System.in);
        StringTokenizer str = new StringTokenizer(sc.nextLine(), " ");
        int n = Integer.parseInt(str.nextToken());
        int k = Integer.parseInt(str.nextToken());
        String s = sc.next();
        int ar[] = new int[n];
        for (int x = 0; x < n; x++) {
            ar[x] = Integer.parseInt(s.substring(x, x + 1));
        }
        if (n == 1) {
            if (k == 1)
                System.out.println(0);
            else
                System.out.println(n);
            return;
        }
        for (int i = 0; i < k && i < n; i++) {
            if (i == 0 && ar[i] != 1) {
                ar[i] = 1;
                continue;
            }
            if (ar[i] != 0) {
                ar[i] = 0;
            } else {
                k++;
            }

        }
        for (int p = 0; p < n; p++) {
            System.out.print(ar[p]);
        }
        System.out.println();

    }
}


import java.util.*;

public class dp21 {
    public static void main(String args[]) {
        Scanner sc = new Scanner(System.in);
        StringTokenizer str = new StringTokenizer(sc.nextLine(), " ");
        int n = Integer.parseInt(str.nextToken());
        int k = Integer.parseInt(str.nextToken());
        String s = sc.next();
        if (n == 1) {
            if (k == 1)
                System.out.println(0);
            else
                System.out.println(n);
            return;
        }
        int i = 0;
        int l = s.length();

        while (i < l && k > 0) {
            char ch = s.charAt(i);
            if (i == 0 && ch != '1') {
                System.out.print(1);
                k--;
            } else if (i == 0 && ch == '1') {
                System.out.print(1);
            }
            if (i != 0) {
                if (ch != '0') {
                    System.out.print(0);
                    k--;
                } else {
                    System.out.print(0);
                }
            }
            i++;
        }
        for (int p = i; p < l; p++) {
            System.out.print(s.charAt(p));
        }
        System.out.println();

    }
}


import java.util.*;

public class dp21 {
    public static void main(String args[]) {
        Scanner sc = new Scanner(System.in);
        StringTokenizer str = new StringTokenizer(sc.nextLine(), " ");
        int n = Integer.parseInt(str.nextToken());
        int k = Integer.parseInt(str.nextToken());
        String s = sc.next();
        if (n == 1) {
            if (k == 1) {
                System.out.println(0);

                return;
            }
        }
        int i = 0;
        int l = s.length();

        while (i < l && k > 0) {
            char ch = s.charAt(i);
            if (i == 0 && ch != '1') {
                System.out.print(1);
                k--;
            } else if (i == 0 && ch == '1') {
                System.out.print(1);
            }
            if (i != 0) {
                if (ch != '0') {
                    System.out.print(0);
                    k--;
                } else {
                    System.out.print(0);
                }
            }
            i++;
        }

        for (int p = i; p < l; p++) {
            System.out.print(s.charAt(p));
        }
        System.out.println();

    }
}


/* package codechef; // don't place package name! */

import java.util.*;
import java.lang.*;
import java.io.*;

/* Name of the class has to be "Main" only if the class is public. */
public class Codechef

{

  public   static int cnt=0,cnt2=0;

	public static void main (String[] args) throws java.lang.Exception
	{
		// your code goes here
		Scanner in = new Scanner(System.in);
		int t=1;
		//in.nextLine();

		while(t>0)
		{

		       int x=in.nextInt(),y=in.nextInt();

		       in.nextLine();

		       String s=in.nextLine();
		       int pos=0;

		      if(x==1)
		      {
		          System.out.println(0);
		      }
		      else if(y==0)
		      {
		       System.out.println(s);
		       //System.out.println(y);
		      }
		      else
		      {
		           if(s.charAt(0)!='1')
		      {
		          y--;
		      }

		          System.out.print(1);

		       int i=1;
		      for(;i<s.length() && i<y+1;i++)
		      {
		         if(s.charAt(i)=='0')
		         {
		             y++;

		         }
		       System.out.print(0);

		      }

		      for(;i<x;i++)
		      {
		          System.out.print(s.charAt(i));
		      }

		      }

		  //System.out.println(1+s.substring(1,s.length()));

		    t--;
		}

	//	System.out.println(x);
	}
}


/* package codechef; // don't place package name! */

import java.util.*;
import java.lang.*;
import java.io.*;

/* Name of the class has to be "Main" only if the class is public. */
public  class Codechef

{

  public   static int cnt=0,cnt2=0;

	public static void main (String[] args) throws java.lang.Exception
	{
		// your code goes here
		Scanner in = new Scanner(System.in);
		int t=1;
		//in.nextLine();

		while(t>0)
		{

		       int x=in.nextInt(),y=in.nextInt();

		       in.nextLine();

		       String s=in.nextLine();
		       int pos=0;
		      if(s.charAt(0)!='1')
		      {
		          y--;
		      }

		      for(int i=1;i<s.length() && i<y+1;i++)
		      {
		         if(s.charAt(i)=='0')
		         {
		             y++;
		             continue;
		         }
		        s=s.substring(0,i)+"0"+s.substring((i+1),s.length());
		        if(i==s.length()-1)
		        {
		            s=s.substring(0,s.length()-1)+"0";
		        }

		      }

		      if(x==1)
		      {
		          System.out.println(0);
		      }
		      else
		  System.out.println(1+s.substring(1,s.length()));

		    t--;
		}

	//	System.out.println(x);
	}
}


/* package codechef; // don't place package name! */

import java.util.*;
import java.lang.*;
import java.io.*;

/* Name of the class has to be "Main" only if the class is public. */
 public class Codechef

{

  public   static int cnt=0,cnt2=0;

	public static void main (String[] args) throws java.lang.Exception
	{
		// your code goes here
		Scanner in = new Scanner(System.in);
		int t=1;
		//in.nextLine();

		while(t>0)
		{

		       int x=in.nextInt(),y=in.nextInt();

		       in.nextLine();

		       String s=in.nextLine();
		       int pos=0;
		      if(s.charAt(0)!='1')
		      {
		          y--;
		      }

		      for(int i=1;i<s.length() && i<y+1;i++)
		      {

		        s=s.substring(0,i)+"0"+s.substring((i+1),s.length());
		        if(i==s.length()-1)
		        {
		            s=s.substring(0,s.length()-1)+"0";
		        }

		      }

		      if(x==1)
		      {
		          System.out.println(0);
		      }
		      else
		  System.out.println(1+s.substring(1,s.length()));

		    t--;
		}

	//	System.out.println(x);
	}
}


/* package codechef; // don't place package name! */

import java.util.*;
import java.lang.*;
import java.io.*;

/* Name of the class has to be "Main" only if the class is public. */
public  class Codechef

{

  public   static int cnt=0,cnt2=0;

	public static void main (String[] args) throws java.lang.Exception
	{
		// your code goes here
		Scanner in = new Scanner(System.in);
		int t=1;
		//in.nextLine();

		while(t>0)
		{

		       int x=in.nextInt(),y=in.nextInt();

		       in.nextLine();

		       String s=in.nextLine();
		       int pos=0;
		      for(int i=1;i<s.length() && i<y+1;i++)
		      {

		        s=s.substring(0,i)+"0"+s.substring((i+1),s.length());
		        if(i==s.length()-1)
		        {
		            s=s.substring(0,s.length()-1)+"0";
		        }

		      }

		      if(x==1)
		      {
		          System.out.println(0);
		      }
		      else
		  System.out.println(1+s.substring(1,s.length()));

		    t--;
		}

	//	System.out.println(x);
	}
}


/* package codechef; // don't place package name! */

import java.util.*;
import java.lang.*;
import java.io.*;

/* Name of the class has to be "Main" only if the class is public. */
public  class Codechef

{

  public   static int cnt=0,cnt2=0;

	public static void main (String[] args) throws java.lang.Exception
	{
		// your code goes here
		Scanner in = new Scanner(System.in);
		int t=1;
		//in.nextLine();

		while(t>0)
		{

		       int x=in.nextInt(),y=in.nextInt();

		       in.nextLine();

		       String s=in.nextLine();
		       int pos=0;
		      if(s.charAt(0)!='1')
		      {
		          y--;
		      }

		      if(x==1)
		      {
		          System.out.println(0);
		      }
		      else if(y==0)
		      {
		       System.out.println(s);
		      }
		      else
		      {
		          System.out.print(1);

		       int i=1;
		      for(;i<s.length() && i<y+1;i++)
		      {
		         if(s.charAt(i)=='0')
		         {
		             y++;

		         }
		       System.out.print(0);

		      }

		      for(;i<x;i++)
		      {
		          System.out.print(s.charAt(i));
		      }
		      }

		  //System.out.println(1+s.substring(1,s.length()));

		    t--;
		}

	//	System.out.println(x);
	}
}


/* package codechef; // don't place package name! */

import java.util.*;
import java.lang.*;
import java.io.*;

/* Name of the class has to be "Main" only if the class is public. */
public  class Codechef

{

  public   static int cnt=0,cnt2=0;

	public static void main (String[] args) throws java.lang.Exception
	{
		// your code goes here
		Scanner in = new Scanner(System.in);
		int t=1;
		//in.nextLine();

		while(t>0)
		{

		       int x=in.nextInt(),y=in.nextInt();

		       in.nextLine();

		       String s=in.nextLine();
		       int pos=0;

		     if(x==1 && y==1)
		     {
		         System.out.println(0);
		     }
		      else if(y==0)
		      {
		       System.out.println(s);
		       //System.out.println(y);
		      }
		      else
		      {
		           if(s.charAt(0)!='1')
		      {
		          y--;
		      }

		          System.out.print(1);

		       int i=1;
		      for(;i<s.length() && i<y+1;i++)
		      {
		         if(s.charAt(i)=='0')
		         {
		             y++;

		         }
		       System.out.print(0);

		      }

		      for(;i<x;i++)
		      {
		          System.out.print(s.charAt(i));
		      }

		      }

		  //System.out.println(1+s.substring(1,s.length()));

		    t--;
		}

	//	System.out.println(x);
	}
}


/* package codechef; // don't place package name! */

import java.util.*;
import java.lang.*;
import java.io.*;

/* Name of the class has to be "Main" only if the class is public. */
public  class Codechef

{

  public   static int cnt=0,cnt2=0;

	public static void main (String[] args) throws java.lang.Exception
	{
		// your code goes here
		Scanner in = new Scanner(System.in);
		int t=1;
		//in.nextLine();

		while(t>0)
		{

		       int x=in.nextInt(),y=in.nextInt();

		       in.nextLine();

		       String s=in.nextLine();
		       int pos=0;
		      for(int i=1;i<s.length() && i<y+1;i++)
		      {

		        s=s.substring(0,i)+"0"+s.substring((i+1),s.length());
		        if(i==s.length()-1)
		        {
		            s=s.substring(0,s.length()-1)+"0";
		        }

		      }

		      if(x==1)
		      {
		          System.out.println(0);
		      }
		      else
		  System.out.println(s);

		    t--;
		}

	//	System.out.println(x);
	}
}


import java.util.*;

public class Main {

    public static void main(String[] args) {
		Scanner in = new Scanner(System.in);
		int count = in.nextInt();
		int b = in.nextInt();
		String number = in.next();
		StringBuilder num = new StringBuilder();
		if (b == 0)
			System.out.println(number);
		else if(count==1 && b>0) System.out.println("0");
		else {
			for (int i = 0; i < b; i++) {
				if (i == 0)
					num.append('1');
				else num.append('0');
			}
			num.append(number.substring(b));
			System.out.println(num);
		}
	}
}


import java.util.*;

public class Main {

    public static void main(String[] args) {
		Scanner in = new Scanner(System.in);
		int count = in.nextInt();
		int b = in.nextInt();
		String number = in.next();
		StringBuilder num = new StringBuilder();
		if (b == 0)
			System.out.println(number);
		else if(count==1 && b>=0) System.out.println("0");
		else {
			for (int i = 0; i < b; i++) {
				if (i == 0 && number.charAt(0)!='1') {
					num.append('1');
				}else if(i==0){
				    num.append('1');
				    if(b<count)
				    b++;
                }
				if(i>0 && number.charAt(i)!='0') {
					num.append('0');
				}else if(i>0) {
				    num.append('0');
				    if(b<count)
                    b++;
                }
			}
			if(num.length()==count)
				System.out.println(num);
			else {
                num.append(number.substring(b));
                System.out.println(num);
            }
		}
	}
}


import java.util.*;
import java.io.*;

public class Q2
{
	static Print print;

	public static void main(String args[]) throws Exception
	{
		Scan scan = new Scan();
		print = new Print();
		int N=scan.scanInt();
		int K=scan.scanInt();
		String no=scan.scanString();
		StringBuilder ans=new StringBuilder();
		if(no.charAt(0)!='1')
		{
			K--;
		}
		ans.append(1);
		int i=1;
		while(i<no.length() && K>0)
		{
			if(no.charAt(i)!='0')
			{
				K--;
			}
			ans.append(0);
			i++;
		}
		for(;i<no.length();i++)
		{
			ans.append(no.charAt(i));
		}
		print.println(ans.toString());
		print.close();
	}

	public static class Print {
		private final BufferedWriter bw;

		public Print() {
			this.bw = new BufferedWriter(new OutputStreamWriter(System.out));
		}

		public void print(Object object) throws IOException {
			bw.append("" + object);
		}

		public void println(Object object) throws IOException {
			print(object);
			bw.append("\n");
		}

		public void close() throws IOException {
			bw.close();
		}
	}

	static class Scan {
		private byte[] buf = new byte[1024 * 1024 * 4];
		private int index;
		private InputStream in;
		private int total;

		public Scan() {
			in = System.in;
		}

		public int scan() throws IOException {
			if (total < 0)
				throw new InputMismatchException();
			if (index >= total) {
				index = 0;
				total = in.read(buf);
				if (total <= 0)
					return -1;
			}
			return buf[index++];
		}

		public int scanInt() throws IOException {
			int integer = 0;
			int n = scan();
			while (isWhiteSpace(n))
				n = scan();
			int neg = 1;
			if (n == '-') {
				neg = -1;
				n = scan();
			}
			while (!isWhiteSpace(n)) {
				if (n >= '0' && n <= '9') {
					integer *= 10;
					integer += n - '0';
					n = scan();
				} else
					throw new InputMismatchException();
			}
			return neg * integer;
		}

		public double scanDouble() throws IOException {
			double doub = 0;
			int n = scan();
			while (isWhiteSpace(n))
				n = scan();
			int neg = 1;
			if (n == '-') {
				neg = -1;
				n = scan();
			}
			while (!isWhiteSpace(n) && n != '.') {
				if (n >= '0' && n <= '9') {
					doub *= 10;
					doub += n - '0';
					n = scan();
				} else
					throw new InputMismatchException();
			}
			if (n == '.') {
				n = scan();
				double temp = 1;
				while (!isWhiteSpace(n)) {
					if (n >= '0' && n <= '9') {
						temp /= 10;
						doub += (n - '0') * temp;
						n = scan();
					} else
						throw new InputMismatchException();
				}
			}
			return doub * neg;
		}

		public long scanLong() throws IOException {
			long ret = 0;
			long c = scan();
			while (c <= ' ') {
				c = scan();
			}

			boolean neg = (c == '-');
			if (neg) {
				c = scan();
			}

			do {
				ret = ret * 10 + c - '0';
			} while ((c = scan()) >= '0' && c <= '9');

			if (neg) {
				return -ret;
			}
			return ret;
		}

		public String scanString() throws IOException {
			StringBuilder sb = new StringBuilder();
			int n = scan();
			while (isWhiteSpace(n))
				n = scan();
			while (!isWhiteSpace(n) || n == ' ') {
				sb.append((char) n);
				n = scan();
			}
			return sb.toString();
		}

		private boolean isWhiteSpace(int n) {
			if (n == ' ' || n == '\n' || n == '\r' || n == '\t' || n == -1)
				return true;
			return false;
		}
	}
}


import java.util.*;
import java.io.*;

public class Q2
{
	static Print print;

	public static void main(String args[]) throws Exception
	{
		Scan scan = new Scan();
		print = new Print();
		int N=scan.scanInt();
		int K=scan.scanInt();
		String no=scan.scanString();
		StringBuilder ans=new StringBuilder();
		if(K==0)
		{
			print.println(no);
		}
		else if(N==1)
		{
			print.println("0");
		}
		else
		{
			if(no.charAt(0)!='1')
			{
				K--;
			}
			ans.append(1);
			int i=1;
			while(i<no.length() && K>0)
			{
				if(no.charAt(i)!='0')
				{
					K--;
				}
				ans.append(0);
				i++;
			}
			for(;i<no.length();i++)
			{
				ans.append(no.charAt(i));
			}
			print.println(ans.toString());
		}
		print.close();
	}

	public static class Print {
		private final BufferedWriter bw;

		public Print() {
			this.bw = new BufferedWriter(new OutputStreamWriter(System.out));
		}

		public void print(Object object) throws IOException {
			bw.append("" + object);
		}

		public void println(Object object) throws IOException {
			print(object);
			bw.append("\n");
		}

		public void close() throws IOException {
			bw.close();
		}
	}

	static class Scan {
		private byte[] buf = new byte[1024 * 1024 * 4];
		private int index;
		private InputStream in;
		private int total;

		public Scan() {
			in = System.in;
		}

		public int scan() throws IOException {
			if (total < 0)
				throw new InputMismatchException();
			if (index >= total) {
				index = 0;
				total = in.read(buf);
				if (total <= 0)
					return -1;
			}
			return buf[index++];
		}

		public int scanInt() throws IOException {
			int integer = 0;
			int n = scan();
			while (isWhiteSpace(n))
				n = scan();
			int neg = 1;
			if (n == '-') {
				neg = -1;
				n = scan();
			}
			while (!isWhiteSpace(n)) {
				if (n >= '0' && n <= '9') {
					integer *= 10;
					integer += n - '0';
					n = scan();
				} else
					throw new InputMismatchException();
			}
			return neg * integer;
		}

		public double scanDouble() throws IOException {
			double doub = 0;
			int n = scan();
			while (isWhiteSpace(n))
				n = scan();
			int neg = 1;
			if (n == '-') {
				neg = -1;
				n = scan();
			}
			while (!isWhiteSpace(n) && n != '.') {
				if (n >= '0' && n <= '9') {
					doub *= 10;
					doub += n - '0';
					n = scan();
				} else
					throw new InputMismatchException();
			}
			if (n == '.') {
				n = scan();
				double temp = 1;
				while (!isWhiteSpace(n)) {
					if (n >= '0' && n <= '9') {
						temp /= 10;
						doub += (n - '0') * temp;
						n = scan();
					} else
						throw new InputMismatchException();
				}
			}
			return doub * neg;
		}

		public long scanLong() throws IOException {
			long ret = 0;
			long c = scan();
			while (c <= ' ') {
				c = scan();
			}

			boolean neg = (c == '-');
			if (neg) {
				c = scan();
			}

			do {
				ret = ret * 10 + c - '0';
			} while ((c = scan()) >= '0' && c <= '9');

			if (neg) {
				return -ret;
			}
			return ret;
		}

		public String scanString() throws IOException {
			StringBuilder sb = new StringBuilder();
			int n = scan();
			while (isWhiteSpace(n))
				n = scan();
			while (!isWhiteSpace(n) || n == ' ') {
				sb.append((char) n);
				n = scan();
			}
			return sb.toString();
		}

		private boolean isWhiteSpace(int n) {
			if (n == ' ' || n == '\n' || n == '\r' || n == '\t' || n == -1)
				return true;
			return false;
		}
	}
}


/**
 * @author egaeus
 * @mail sebegaeusprogram@gmail.com
 * @veredict Accepted
 * @url <https://codeforces.com/problemset/problem/1230/B>
 * @category adhoc
 * @date 30/09/2019
 **/

import java.io.BufferedReader;
import java.io.InputStreamReader;
import java.util.StringTokenizer;

import static java.lang.Integer.parseInt;

public class CF1230B {
    public static void main(String args[]) throws Throwable {
        BufferedReader in = new BufferedReader(new InputStreamReader(System.in));
        for (String ln; (ln = in.readLine()) != null; ) {
            StringTokenizer st = new StringTokenizer(ln);
            int N = parseInt(st.nextToken()), K = parseInt(st.nextToken());
            char[] A = in.readLine().toCharArray();
            if (N == 1 && K >= 1)
                System.out.println(0);
            else {
                for (int i = 0, j = 0; i < K && j < N; j++)
                    if (j == 0 && A[j] != '1') {
                        i++;
                        A[j] = '1';
                    } else if (j > 0 && A[j] != '0') {
                        i++;
                        A[j] = '0';
                    }
                System.out.println(new String(A));
            }
        }
    }
}


import java.util.Scanner;

public class SydneyTest {
  public static void main(String[] args) {
    Scanner input = new Scanner(System.in);
    int length = input.nextInt();
    int chances = input.nextInt();
    String digit = input.next();

    if(chances == 0 ) {
      System.out.println(digit);
      return;
    }

    if(length == 1) {
      if(Integer.parseInt(digit) > 0) {
        System.out.println("0");
        return;
      }
    }
    StringBuilder stringBuilder = new StringBuilder(String.valueOf(digit));
    int counter = 0;
    for(int x=0;x<length;x++) {
      if(x == 0 && Character.getNumericValue(stringBuilder.charAt(x)) > 1) {
        stringBuilder.setCharAt(0, '1');
        counter++;
      }else if(x != 0 && Character.getNumericValue(stringBuilder.charAt(x)) > 0) {
        stringBuilder.setCharAt(x, '0');
        counter++;
      }
      if(counter == chances) {
        break;
      }
    }

    System.out.println(stringBuilder.toString());
  }

}


import java.util.Scanner;

public class SydneyTest {
  public static void main(String[] args) {
    Scanner input = new Scanner(System.in);
    int length = input.nextInt();
    int chances = input.nextInt();
    int digit = input.nextInt();

    if(chances == 0 ) {
      System.out.println(digit);
      return;
    }

    if(length == 1) {
      if(digit > 0) {
        System.out.println("0");
        return;
      }
    }
    StringBuilder stringBuilder = new StringBuilder(String.valueOf(digit));
    int counter = 0;
    for(int x=0;x<length;x++) {
      if(x == 0 && Character.getNumericValue(stringBuilder.charAt(x)) > 1) {
        stringBuilder.setCharAt(0, '1');
        counter++;
      }else if(x != 0 && Character.getNumericValue(stringBuilder.charAt(x)) > 0) {
        stringBuilder.setCharAt(x, '0');
        counter++;
      }
      if(counter == chances) {
        break;
      }
    }

    System.out.println(stringBuilder.toString());
  }

}


import java.util.*;
import java.io.*;
public class codeforces {
	public static void main(String[] args) throws IOException
	{
		try{

Scanner sc=new Scanner(System.in);

int n=sc.nextInt();
int k=sc.nextInt();
String str=sc.next();
StringBuffer br=new  StringBuffer();
if(k==0){
    System.out.println(str);
    return;
}
if(n==1){
    br.append("0");
    System.out.println(br);
    return;
}
int j=0;
int pointer=0;
if(Integer.parseInt(String.valueOf(str.charAt(0)))>1){
j++;
pointer++;
br.append("1");
}
if(Integer.parseInt(String.valueOf(str.charAt(0)))==1){
    j++;
    br.append("1");

}
while(pointer<k &&  j<n){
if(!String.valueOf(str.charAt(j)).equals("0")){
    br.append("0");
pointer++;
}
else{
    br.append("0");

}
j++;

}
while(j<n){
    br.append(String.valueOf(str.charAt(j)));
    j++;
}
System.out.println(br);

    }
        catch(Exception e){
            System.out.println(e);
        }

  }

}


import java.util.Scanner;

public class Minimizing {
    public static void main(String[] args) {
        Scanner s = new Scanner(System.in);
        int n = s.nextInt();
        int k = s.nextInt();
        int[] S = new int[n];
        int br = 0;
        for(int i = S.length - 1; i >= 0; i--) S[i] = s.nextInt();
        if(S.length == 1 && k >= 1) S[0] = 0;
        else {
            for (int i = S.length - 1; i >= 0; i--) {
                if (br == k) break;
                if (i == S.length - 1 && S[i] != 1) {
                    S[i] = 1;
                    br++;
                } else if (i < S.length - 1) {
                    S[i] = 0;
                    br++;
                }
            }
        }
        for(int i = S.length - 1; i >= 0; i--) System.out.print(S[i]);
    }
}


import java.util.Scanner;

public class Minimizing {
    public static void main(String[] args) {
        Scanner s = new Scanner(System.in);
        int n = s.nextInt();
        int k = s.nextInt();
        String arr = s.next();
        char[] S = arr.toCharArray();
        int br = 0;
        if(S.length == 1 && k >= 1) S[0] = '0';
        else {
            for (int i = 0; i < S.length; i++) {
                if (br == k) break;
                if (i == 0 && S[i] != '1') {
                    S[i] = '1';
                    br++;
                } else if (i > 0 && S[i] != '0') {
                    S[i] = '0';
                    br++;
                }
            }
        }
        for(int i = 0; i < S.length; i++) System.out.print(S[i]);
    }
}


import java.util.Arrays;
import java.util.Scanner;

public class Main {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int[] a = new int[4];
        for(int i=0;i<4;i++)a[i] = sc.nextInt();
        Arrays.sort(a);

        if((a[0]+a[3])==(a[1]+a[2]))System.out.println("YES");
        else if(a[0]+a[2]==a[1]+a[3])System.out.println("YES");
        else if(a[0]+a[1]+a[2]==a[3])System.out.println("YES");
        else System.out.println("NO");

    }
}


import java.util.Scanner;

public class Main {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        int k = sc.nextInt();
        char[] c = sc.next().toCharArray();
        if (n == 1 & k > 0)
            System.out.println(0);
        else if (k != 0) {
            if (c[0] != '1') {
                k--;
                c[0] = '1';
            }
            for (int i = 1; i < n; i++) {
                if (k == 0)
                    break;
                if (c[i] != '0') {
                    k--;
                    c[i] = '0';
                }
            }
            for (int i = 0; i < n; i++)
                System.out.print(c[i]);
        } else {
            for (int i = 0; i < n; i++)
                System.out.print(c[i]);
        }
    }
}


import java.util.Scanner;

public class Main {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        int k = sc.nextInt();
        char[] c = sc.next().toCharArray();
        if (n == 1 & k > 0)
            System.out.println(0);
        else {
            if (c[0] != '1') {
                k--;
                c[0] = '1';
            }
            for (int i = 1; i < n; i++) {
                if (k == 0)
                    break;
                if (c[i] != '0') {
                    k--;
                    c[i] = '0';
                }
            }
            for (int i = 0; i < n; i++)
                System.out.print(c[i]);
        }
    }
}


import java.util.*;
public class Solution
{
    public static void main(String[] args)
    {
        Scanner sc=new Scanner(System.in);
        int n=sc.nextInt();
        int k=sc.nextInt();
        String s=sc.next();
        int count=0;
        char ch[]=s.toCharArray();
        if(n>1)
        {
            for(int i=0;i<ch.length;i++)
            {
                if(count==k)
                {
                    break;
                }
                if(ch[0]=='0' || ch[0]>='2')
                {
                    ch[0]='1';
                    count++;
                }
                if(i!=0 && ch[i]!=0)
                {
                    ch[i]='0';
                    count++;
                }
            }
               for(int i=0;i<n;i++)
             {
                 System.out.print(ch[i]);
             }
        }
        if(n==1)
        {
            System.out.println("0");
        }

    }
}


import java.util.*;
public class Solution
{
    public static void main(String[] args)
    {
        Scanner sc=new Scanner(System.in);
        int n=sc.nextInt();
        int k=sc.nextInt();
        String s=sc.next();

         char ch[]=s.toCharArray();
         int count=0;
         if((n==1 && k==1) && s=="1")
         {
             System.out.println("0");
         }
	else
	{

            for(int i=1;i<ch.length;i++)
            {
                if(ch[i]>'0' && ch[i]<='9')
                {
                    ch[i]='0';
                    count++;
                    if(  count==k-1 || (count<=k-1 && i==n-1))
                    {
                        ch[0]='1';
                        break;
                    }
                }
            }
        }
                     for(int j=0;j<ch.length;j++)
                      {
                        System.out.print(ch[j]);
                      }
    }
}


import java.util.*;
public class Solution
{
    public static void main(String[] args)
    {
        Scanner sc=new Scanner(System.in);
        int n=sc.nextInt();
        int k=sc.nextInt();
        String s=sc.next();

         char ch[]=s.toCharArray();
         int count=0;
         if((n==1 && k==1) && s=="1")
         {
             System.out.println("0");
         }

            for(int i=1;i<ch.length;i++)
            {
                if(ch[i]>'0' && ch[i]<='9')
                {
                    ch[i]='0';
                    count++;
                    if(  count==k-1 || (count<=k-1 && i==n-1))
                    {
                        ch[0]='1';
                        break;
                    }
                }
            }

                     for(int j=0;j<ch.length;j++)
                      {
                        System.out.print(ch[j]);
                       }
    }
}


import java.util.*;
public class Solution
{
    public static void main(String[] args)
    {
        Scanner sc=new Scanner(System.in);
        int n=sc.nextInt();
        int k=sc.nextInt();
        String s=sc.next();

         char ch[]=s.toCharArray();
         int count=0;
         if((n==1 && k==1))
         {
             System.out.print("0");
         }
         else if(!((n==1 && k==1)))
         {
              for(int i=1;i<ch.length;i++)
            {
                if(ch[i]>'0' && ch[i]<='9')
                {
                    ch[i]='0';
                    count++;
                    if(  count==k-1 || (count<=k-1 && i==n-1))
                    {
                        ch[0]='1';
                        break;
                    }
                }
            }
                 for(int j=0;j<ch.length;j++)
                     {
                        System.out.print(ch[j]);
                 }
        }
    }
}


    import java.util.*;
    public class Solution{
    	public static void main(String[] args) {
    		Scanner sc=new Scanner(System.in);
    		int n=sc.nextInt();
    		int k=sc.nextInt();

    		String s=sc.next();

    		if(k==0)
    		{
    			System.out.println(s);
    			return;

    		}

    		if(n==1  && k==1)
    		{
    			System.out.println("0");
    			return;
    		}

    		if(s.charAt(0)!='1')
            {
               System.out.print("1");
               k--;

            }
           else  if(s.charAt(0)=='1')
            {
               System.out.print("1");

            }
    int  c=0;
        for(int i=1;i<n;i++)
        {

           if(s.charAt(i)!='0' && k!=0)
            {
               System.out.print("0");
               k--;

            }
            else if(s.charAt(i)=='0' && k!=0)
            {
               System.out.print("0");
            }
            else if(k==0)
            {
                System.out.print(s.charAt(i));
            }
        }

    	}

    }


import java.util.*;
public class Solution
{
    public static void main(String[] args)
    {
        Scanner sc=new Scanner(System.in);
        int n=sc.nextInt();
        int k=sc.nextInt();
        String s=sc.next();
        if(n==1)
        {
            System.out.println("0");
        }
         char ch[]=s.toCharArray();
        int count=0;
        if(n>1)
        {
            for(int i=1;i<ch.length;i++)
            {
                if(ch[i]>'0' && ch[i]<='9')
                {
                    ch[i]='0';
                    count++;
                    if(count==k-1)
                    {
                        break;
                    }
                }
            }
            ch[0]='1';
            for(int i=0;i<ch.length;i++)
            {
                System.out.print(ch[i]);
            }
        }
    }
}


import java.util.*;
public class Solution
{
    public static void main(String[] args)
    {
        Scanner sc=new Scanner(System.in);
        int n=sc.nextInt();
        int k=sc.nextInt();
        String s=sc.next();

         char ch[]=s.toCharArray();
         int count=0;
         if((n==1 && k==1) && s=="1")
         {
             System.out.println("1");
         }
	else
	{

            for(int i=1;i<ch.length;i++)
            {
                if(ch[i]>'0' && ch[i]<='9')
                {
                    ch[i]='0';
                    count++;
                    if(  count==k-1 || (count<=k-1 && i==n-1))
                    {
                        ch[0]='1';
                        break;
                    }
                }
            }
        }
                     for(int j=0;j<ch.length;j++)
                      {
                        System.out.print(ch[j]);
                      }
    }
}


import java.util.*;
public class Solution
{
    public static void main(String[] args)
    {
        Scanner sc=new Scanner(System.in);
        int n=sc.nextInt();
        int k=sc.nextInt();
        String s=sc.next();
        if(n==1 && k!=0)
        {
            System.out.println("0");
        }
        if(n>=1 && k==0)
        {
            System.out.println(s);
        }
         char ch[]=s.toCharArray();
        int count=0;
        if(n>1 && k>1)
        {
            for(int i=1;i<ch.length;i++)
            {
                if(ch[i]>'0' && ch[i]<='9')
                {
                    ch[i]='0';
                    count++;
                    if(count==k-1)
                    {
                        break;
                    }
                }
            }
            ch[0]='1';
            for(int i=0;i<ch.length;i++)
            {
                System.out.print(ch[i]);
            }
        }
    }
}


import java.io.OutputStream;
import java.io.IOException;
import java.io.InputStream;
import java.io.PrintWriter;
import java.util.Scanner;

/**
 * Built using CHelper plug-in
 * Actual solution is at the top
 *
 * @author ky112233
 */
public class Main {
    public static void main(String[] args) {
        InputStream inputStream = System.in;
        OutputStream outputStream = System.out;
        Scanner in = new Scanner(inputStream);
        PrintWriter out = new PrintWriter(outputStream);
        TaskB solver = new TaskB();
        solver.solve(1, in, out);
        out.close();
    }

    static class TaskB {
        public void solve(int testNumber, Scanner in, PrintWriter out) {
            int n = in.nextInt();
            int k = in.nextInt();
            String str = in.next();
            if (n == 1) {
                if (k > 0) {
                    out.println(0);
                } else {
                    out.println(n);
                }
                return;
            }
            for (int i = 0; i < n; i++) {
                if (i == 0) {
                    if (k > 0) {
                        k--;
                        if (str.charAt(i) > '1') {
                            out.print(1);
                        } else {
                            k++;
                            out.print(str.charAt(i));
                        }
                    } else out.print(str.charAt(i));
                } else {
                    if (k > 0 && str.charAt(i) > '0') {
                        k--;
                        out.print(0);
                    } else out.print(str.charAt(i));
                }
            }
        }

    }
}


import java.io.OutputStream;
import java.io.IOException;
import java.io.InputStream;
import java.io.PrintWriter;
import java.util.Scanner;

/**
 * Built using CHelper plug-in
 * Actual solution is at the top
 *
 * @author ky112233
 */
public class Main {
    public static void main(String[] args) {
        InputStream inputStream = System.in;
        OutputStream outputStream = System.out;
        Scanner in = new Scanner(inputStream);
        PrintWriter out = new PrintWriter(outputStream);
        TaskB solver = new TaskB();
        solver.solve(1, in, out);
        out.close();
    }

    static class TaskB {
        public void solve(int testNumber, Scanner in, PrintWriter out) {
            int n = in.nextInt();
            int k = in.nextInt();
            String str = in.next();
            if (n == 1) {
                if (k > 0) {
                    out.println(0);
                } else {
                    out.println(str);
                }
                return;
            }
            for (int i = 0; i < n; i++) {
                if (i == 0) {
                    if (k > 0) {
                        k--;
                        if (str.charAt(i) > '1') {
                            out.print(1);
                        } else {
                            k++;
                            out.print(str.charAt(i));
                        }
                    } else out.print(str.charAt(i));
                } else {
                    if (k > 0 && str.charAt(i) > '0') {
                        k--;
                        out.print(0);
                    } else out.print(str.charAt(i));
                }
            }
        }

    }
}


import java.util.*;
public class AniaAndMinimizing {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int n=sc.nextInt();
		int k=sc.nextInt();
		String s = sc.next();
		if(n==1 && k>=1) System.out.println("0");
		else if(k==0) System.out.println(s);
		else
		{
			if(s.charAt(0)!='1' && k>0) { k--;}
			System.out.print("1");
			int j = 1;
			while(k>0 && j<s.length()) {
				if(s.charAt(j++)!='0') k--;
				System.out.print("0");
			}
			while(j<s.length()) System.out.print(s.charAt(j++));
		}

	}

}


import com.sun.source.tree.ReturnTree;

import java.io.*;
import java.util.*;

public class Main {

    private  static void solver(InputReader sc, PrintWriter out) {
       int n  = sc.nextInt();
        int k = sc.nextInt();
        String s = sc.next();
        StringBuilder sb = new StringBuilder("");
        int count=0;
        if(n==1){
            if(k>0)
                out.println("0");
            else
                out.println(s);
            return;
        }
        if(s.charAt(0)=='1')
            sb.append("1");
        else if(s.charAt(0)>'1'){
           if(count<k) {
               count++;
               sb.append("1");
           }else
               sb.append(s.charAt(0));
        }
        for(int i=1; i<n; i++){
            if(count<k) {
                int ch = (int) s.charAt(i) - 48;
                if (ch != 0) {
                    count++;
                    sb.append("0");
                } else {
                    sb.append(ch);
                }
            }else{
                sb.append(s.charAt(i));
            }
        }
        out.print(sb);
    }
    public static void main(String[] args) throws Exception{
        InputStream inputStream = System.in;
        OutputStream outputStream = System.out;
        InputReader in = new InputReader(inputStream);
        PrintWriter out = new PrintWriter(outputStream);
        solver(in,out);
        out.close();
    }
    static class InputReader {
        public BufferedReader reader;
        public StringTokenizer tokenizer;

        public InputReader(InputStream stream) {
            reader = new BufferedReader(new InputStreamReader(stream), 32768);
            tokenizer = null;
        }

        public String next() {
            while (tokenizer == null || !tokenizer.hasMoreTokens()) {
                try {
                    tokenizer = new StringTokenizer(reader.readLine());
                } catch (IOException e) {
                    throw new RuntimeException(e);
                }
            }
            return tokenizer.nextToken();
        }

        public int nextInt() {
            return Integer.parseInt(next());
        }
        public long nextLong(){
            return Long.parseLong(next());
        }

        public long[] readLongArr(int n){
            long arr[] = new long[n];
            for(int i=0; i<n; i++){
                arr[i] = nextLong();
            }
            return arr;
        }
        public int[] readIntArr(int n){
            int arr[] = new int[n];
            for(int i=0; i<n; i++){
                arr[i] = nextInt();
            }
            return arr;
        }
    }
}


import com.sun.source.tree.ReturnTree;

import java.io.*;
import java.util.*;

public class Main {

    private  static void solver(InputReader sc, PrintWriter out) {
       int n  = sc.nextInt();
        int k = sc.nextInt();
        String s = sc.next();
        StringBuilder sb = new StringBuilder("");
        int count=0;
        if(n==1){
            if(k>0)
                out.println("0");
            else
                out.println(s);
            return;
        }
        if((int)(s.charAt(0)-48)>=1){
           if(count<k) {
               count++;
               sb.append("1");
           }else
               sb.append(s.charAt(0));
        }
        for(int i=1; i<n; i++){
            if(count<k) {
                int ch = (int) s.charAt(i) - 48;
                if (ch != 0) {
                    count++;
                    sb.append("0");
                } else {
                    sb.append(ch);
                }
            }else{
                sb.append(s.charAt(i));
            }
        }
        out.print(sb);
    }
    public static void main(String[] args) throws Exception{
        InputStream inputStream = System.in;
        OutputStream outputStream = System.out;
        InputReader in = new InputReader(inputStream);
        PrintWriter out = new PrintWriter(outputStream);
        solver(in,out);
        out.close();
    }
    static class InputReader {
        public BufferedReader reader;
        public StringTokenizer tokenizer;

        public InputReader(InputStream stream) {
            reader = new BufferedReader(new InputStreamReader(stream), 32768);
            tokenizer = null;
        }

        public String next() {
            while (tokenizer == null || !tokenizer.hasMoreTokens()) {
                try {
                    tokenizer = new StringTokenizer(reader.readLine());
                } catch (IOException e) {
                    throw new RuntimeException(e);
                }
            }
            return tokenizer.nextToken();
        }

        public int nextInt() {
            return Integer.parseInt(next());
        }
        public long nextLong(){
            return Long.parseLong(next());
        }

        public long[] readLongArr(int n){
            long arr[] = new long[n];
            for(int i=0; i<n; i++){
                arr[i] = nextLong();
            }
            return arr;
        }
        public int[] readIntArr(int n){
            int arr[] = new int[n];
            for(int i=0; i<n; i++){
                arr[i] = nextInt();
            }
            return arr;
        }
    }
}


import com.sun.source.tree.ReturnTree;

import java.io.*;
import java.util.*;

public class Main {

    private  static void solver(InputReader sc, PrintWriter out) {
       int n  = sc.nextInt();
        int k = sc.nextInt();
        String s = sc.next();
        StringBuilder sb = new StringBuilder("");
        int count=0;
        if(n==1){
            if(k>0)
                out.println("0");
            else
                out.println(s);
            return;
        }
        if((int)(s.charAt(0)-48)>=1){
            count++;
            sb.append("1");
        }
        for(int i=1; i<n; i++){
            if(count<k) {
                int ch = (int) s.charAt(i) - 48;
                if (ch != 0) {
                    count++;
                    sb.append("0");
                } else {
                    sb.append(ch);
                }
            }else{
                sb.append(s.charAt(i));
            }
        }
        out.print(sb);
    }
    public static void main(String[] args) throws Exception{
        InputStream inputStream = System.in;
        OutputStream outputStream = System.out;
        InputReader in = new InputReader(inputStream);
        PrintWriter out = new PrintWriter(outputStream);
        solver(in,out);
        out.close();
    }
    static class InputReader {
        public BufferedReader reader;
        public StringTokenizer tokenizer;

        public InputReader(InputStream stream) {
            reader = new BufferedReader(new InputStreamReader(stream), 32768);
            tokenizer = null;
        }

        public String next() {
            while (tokenizer == null || !tokenizer.hasMoreTokens()) {
                try {
                    tokenizer = new StringTokenizer(reader.readLine());
                } catch (IOException e) {
                    throw new RuntimeException(e);
                }
            }
            return tokenizer.nextToken();
        }

        public int nextInt() {
            return Integer.parseInt(next());
        }
        public long nextLong(){
            return Long.parseLong(next());
        }

        public long[] readLongArr(int n){
            long arr[] = new long[n];
            for(int i=0; i<n; i++){
                arr[i] = nextLong();
            }
            return arr;
        }
        public int[] readIntArr(int n){
            int arr[] = new int[n];
            for(int i=0; i<n; i++){
                arr[i] = nextInt();
            }
            return arr;
        }
    }
}


import java.io.*;
import java.util.*;
import java.math.*;
import java.lang.*;

import static java.lang.Math.*;

public class Cf182 implements Runnable
{
	static class InputReader
	{
		private InputStream stream;
		private byte[] buf = new byte[1024];
		private int curChar;
		private int numChars;
		private SpaceCharFilter filter;
		private BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		public InputReader(InputStream stream)
		{
			this.stream = stream;
		}

		public int read()
		{
			if (numChars==-1)
				throw new InputMismatchException();

			if (curChar >= numChars)
			{
				curChar = 0;
				try
				{
					numChars = stream.read(buf);
				}
				catch (IOException e)
				{
					throw new InputMismatchException();
				}

				if(numChars <= 0)
					return -1;
			}
			return buf[curChar++];
		}

		public String nextLine()
		{
			String str = "";
			try
			{
				str = br.readLine();
			}
			catch (IOException e)
			{
				e.printStackTrace();
			}
			return str;
		}
		public int nextInt()
		{
			int c = read();

			while(isSpaceChar(c))
				c = read();

			int sgn = 1;

			if (c == '-')
			{
				sgn = -1;
				c = read();
			}

			int res = 0;
			do
			{
				if(c<'0'||c>'9')
					throw new InputMismatchException();
				res *= 10;
				res += c - '0';
				c = read();
			}
			while (!isSpaceChar(c));

			return res * sgn;
		}

		public long nextLong()
		{
			int c = read();
			while (isSpaceChar(c))
				c = read();
			int sgn = 1;
			if (c == '-')
			{
				sgn = -1;
				c = read();
			}
			long res = 0;

			do
			{
				if (c < '0' || c > '9')
					throw new InputMismatchException();
				res *= 10;
				res += c - '0';
				c = read();
			}
			while (!isSpaceChar(c));
				return res * sgn;
		}

		public double nextDouble()
		{
			int c = read();
			while (isSpaceChar(c))
				c = read();
			int sgn = 1;
			if (c == '-')
			{
				sgn = -1;
				c = read();
			}
			double res = 0;
			while (!isSpaceChar(c) && c != '.')
			{
				if (c == 'e' || c == 'E')
					return res * Math.pow(10, nextInt());
				if (c < '0' || c > '9')
					throw new InputMismatchException();
				res *= 10;
				res += c - '0';
				c = read();
			}
			if (c == '.')
			{
				c = read();
				double m = 1;
				while (!isSpaceChar(c))
				{
					if (c == 'e' || c == 'E')
						return res * Math.pow(10, nextInt());
					if (c < '0' || c > '9')
						throw new InputMismatchException();
					m /= 10;
					res += (c - '0') * m;
					c = read();
				}
			}
			return res * sgn;
		}

		public String readString()
		{
			int c = read();
			while (isSpaceChar(c))
				c = read();
			StringBuilder res = new StringBuilder();
			do
			{
				res.appendCodePoint(c);
				c = read();
			}
			while (!isSpaceChar(c));

			return res.toString();
		}

		public boolean isSpaceChar(int c)
		{
			if (filter != null)
				return filter.isSpaceChar(c);
			return c == ' ' || c == '\n' || c == '\r' || c == '\t' || c == -1;
		}

		public String next()
		{
			return readString();
		}

		public interface SpaceCharFilter
		{
			public boolean isSpaceChar(int ch);
		}
	}
	public static void main(String args[]) throws Exception
	{
		new Thread(null, new Cf182(),"Main",1<<27).start();
	}

	public static long gcd(long a, long b)
	{
		if (a == 0)
			return b;
		return gcd(b % a, a);
	}

	public static long findGCD(long arr[], int n)
	{
		long result = arr[0];
		for (int i = 1; i < n; i++)
			result = gcd(arr[i], result);
		return result;
	}
// 	int a[]=new int[100001];
//     for(int i=2;i<=100000;i++)
//     {
//   if(a[i]!=1)
//       {
//           a[i]=0;
//           for(int j=2*i;j<=100000;j=j+i)
//           {
//               a[j]=1;
//           }
//       }
//     }
    public static boolean distinct (int i)
    {
        int num = i;
        HashMap<Integer,Integer> map = new HashMap<>();
        while(num>0)
        {
            int temp = num%10;
            if(map.containsKey(temp))
                return false;
            else
                map.put(temp,0);
            num = num/10;
        }
        return true;
    }
	public void run()
	{
		InputReader sc = new InputReader(System.in);
		PrintWriter w = new PrintWriter(System.out);
		int n = sc.nextInt();
		int k = sc.nextInt();
		String s = sc.next();
		if(k==0)
		    System.out.println(s);
		else if(n==1)
		{
		    if(k>=1)
		        System.out.println("0");
		    else
		        System.out.println(s);
		}
		else
		{
    		for(int i=0;i<n;i++)
    		{
    		    if(k>0)
    		    {
        		    if(i==0)
        		    {
        		        if(s.charAt(i)=='1')
        		            System.out.print("1");
        		        else
        		        {
        		        k--;
        		        System.out.print("1");
        		        }
        		    }
        		    else if(s.charAt(i)=='0')
        		        System.out.print("0");
        		    else
        		    {
        		        System.out.print("0");
        		        k--;
        		    }
    		    }
    		    else
    		        System.out.print(s.charAt(i));
    		}
		}
	}
}


import java.io.*;
import java.util.*;
import java.math.*;
import java.lang.*;

import static java.lang.Math.*;

public class Cf182 implements Runnable
{
	static class InputReader
	{
		private InputStream stream;
		private byte[] buf = new byte[1024];
		private int curChar;
		private int numChars;
		private SpaceCharFilter filter;
		private BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		public InputReader(InputStream stream)
		{
			this.stream = stream;
		}

		public int read()
		{
			if (numChars==-1)
				throw new InputMismatchException();

			if (curChar >= numChars)
			{
				curChar = 0;
				try
				{
					numChars = stream.read(buf);
				}
				catch (IOException e)
				{
					throw new InputMismatchException();
				}

				if(numChars <= 0)
					return -1;
			}
			return buf[curChar++];
		}

		public String nextLine()
		{
			String str = "";
			try
			{
				str = br.readLine();
			}
			catch (IOException e)
			{
				e.printStackTrace();
			}
			return str;
		}
		public int nextInt()
		{
			int c = read();

			while(isSpaceChar(c))
				c = read();

			int sgn = 1;

			if (c == '-')
			{
				sgn = -1;
				c = read();
			}

			int res = 0;
			do
			{
				if(c<'0'||c>'9')
					throw new InputMismatchException();
				res *= 10;
				res += c - '0';
				c = read();
			}
			while (!isSpaceChar(c));

			return res * sgn;
		}

		public long nextLong()
		{
			int c = read();
			while (isSpaceChar(c))
				c = read();
			int sgn = 1;
			if (c == '-')
			{
				sgn = -1;
				c = read();
			}
			long res = 0;

			do
			{
				if (c < '0' || c > '9')
					throw new InputMismatchException();
				res *= 10;
				res += c - '0';
				c = read();
			}
			while (!isSpaceChar(c));
				return res * sgn;
		}

		public double nextDouble()
		{
			int c = read();
			while (isSpaceChar(c))
				c = read();
			int sgn = 1;
			if (c == '-')
			{
				sgn = -1;
				c = read();
			}
			double res = 0;
			while (!isSpaceChar(c) && c != '.')
			{
				if (c == 'e' || c == 'E')
					return res * Math.pow(10, nextInt());
				if (c < '0' || c > '9')
					throw new InputMismatchException();
				res *= 10;
				res += c - '0';
				c = read();
			}
			if (c == '.')
			{
				c = read();
				double m = 1;
				while (!isSpaceChar(c))
				{
					if (c == 'e' || c == 'E')
						return res * Math.pow(10, nextInt());
					if (c < '0' || c > '9')
						throw new InputMismatchException();
					m /= 10;
					res += (c - '0') * m;
					c = read();
				}
			}
			return res * sgn;
		}

		public String readString()
		{
			int c = read();
			while (isSpaceChar(c))
				c = read();
			StringBuilder res = new StringBuilder();
			do
			{
				res.appendCodePoint(c);
				c = read();
			}
			while (!isSpaceChar(c));

			return res.toString();
		}

		public boolean isSpaceChar(int c)
		{
			if (filter != null)
				return filter.isSpaceChar(c);
			return c == ' ' || c == '\n' || c == '\r' || c == '\t' || c == -1;
		}

		public String next()
		{
			return readString();
		}

		public interface SpaceCharFilter
		{
			public boolean isSpaceChar(int ch);
		}
	}
	public static void main(String args[]) throws Exception
	{
		new Thread(null, new Cf182(),"Main",1<<27).start();
	}

	public static long gcd(long a, long b)
	{
		if (a == 0)
			return b;
		return gcd(b % a, a);
	}

	public static long findGCD(long arr[], int n)
	{
		long result = arr[0];
		for (int i = 1; i < n; i++)
			result = gcd(arr[i], result);
		return result;
	}
// 	int a[]=new int[100001];
//     for(int i=2;i<=100000;i++)
//     {
//   if(a[i]!=1)
//       {
//           a[i]=0;
//           for(int j=2*i;j<=100000;j=j+i)
//           {
//               a[j]=1;
//           }
//       }
//     }
    public static boolean distinct (int i)
    {
        int num = i;
        HashMap<Integer,Integer> map = new HashMap<>();
        while(num>0)
        {
            int temp = num%10;
            if(map.containsKey(temp))
                return false;
            else
                map.put(temp,0);
            num = num/10;
        }
        return true;
    }
	public void run()
	{
		InputReader sc = new InputReader(System.in);
		PrintWriter w = new PrintWriter(System.out);
		int n = sc.nextInt();
		int k = sc.nextInt();
		String s = sc.next();
		if(k==0)
		    System.out.println(s);
		else if(n==1)
		{
		    if(k>=1)
		        System.out.println("0");
		    else
		        System.out.println(s);
		}
		else
		{
    		for(int i=0;i<n;i++)
    		{
    		    if(k>0)
    		    {
        		    if(i==0)
        		    {
        		        System.out.print("1");
        		        k--;
        		    }
        		    else if(s.charAt(i)=='0')
        		        System.out.print("0");
        		    else
        		    {
        		        System.out.print("0");
        		        k--;
        		    }
    		    }
    		    else
    		        System.out.print(s.charAt(i));
    		}
		}
	}
}


import java.util.*;
public class JavaApplication9 {
    public static int n;
    public static ArrayList<Integer>[] gp;
    public static void main(String[] args) {
        Scanner io = new Scanner(System.in);
        //int t = io.nextInt();
        int t = 1;
        while(t-- != 0) {
            int n = io.nextInt(), k = io.nextInt();
            String s = io.next();
            if(n==1 && k >= 1) s = "0";
            for(int i = 0; i < n && k > 0; i++) {
                if(s.charAt(i)=='0') continue;
                if(i == 0 && s.charAt(i)=='1') continue;
                else if(i == 0) s = "1"+((n > 1) ? s.substring(i+1) : "");
                else if(s.charAt(i)=='0') continue;
                else s = s.substring(0, i)+"0"+((n > i+1) ? s.substring(i+1) : "");
                k--;
            }
            System.out.println(s);
        }
    }
}


import java.util.*;
public class JavaApplication9 {
    public static int n;
    public static ArrayList<Integer>[] gp;
    public static void main(String[] args) {
        Scanner io = new Scanner(System.in);
        //int t = io.nextInt();
        int t = 1;
        while(t-- != 0) {
            int n = io.nextInt(), k = io.nextInt();
            char[] str = io.next().toCharArray();
            if(n==1 && k >= 1) str[0] = '0';
            for(int i = 0; i < n && k > 0; i++) {
                if(str[i]=='0') continue;
                if(i == 0 && str[i]=='1') continue;
                else if(i == 0) str[i] = '1';
                else if(str[i]=='0') continue;
                else str[i] = '0';
                k--;
            }
            System.out.println(new String(str));
        }
    }
}