String by Deletions


You are given a decimal string ss and an integer kk.

Delete exactly kk digits from ss so that the remaining digits, in their original order, form the smallest possible number.

If the resulting number has leading zeroes, do not print them. If every digit is deleted, or the result is all zeroes, print 0.

Input

The first line contains the string ss.

The second line contains the integer kk.

Output

Print the smallest possible number after deleting exactly kk digits.

Constraints

  • 1≤∣s∣≤2⋅1051 \le |s| \le 2 \cdot 10^5
  • 0≤k≤∣s∣0 \le k \le |s|
  • ss consists only of digits 0 through 9

Example 1

Input 1
1432219
3
Output 1
1219
Explanation

Deleting the digits 4, 3, and 2 gives the smallest possible result.

Example 2

Input 2
10200
1
Output 2
200
Explanation

Deleting the leading 1 gives 0200, which is printed as 200.

Example 3

Input 3
10
2
Output 3
0

Comments0


No comments yet

Be the first to comment.

New comment


Log in to join the discussion.