Company: Decimal_Point
Difficulty: medium
Smallest Payable Amount Without Disliked Digits Bob has to settle a bill. The shopkeeper will accept any whole number of dollars that is **at least** `N`, but Bob is superstitious about digits: there are `k` decimal digits that he dislikes, and he refuses to hand over an amount whose decimal representation contains even one of them. Naturally, Bob also wants to part with as little money as possible. Given `N` and the list of digits Bob dislikes, determine the amount Bob ends up paying: the smallest integer greater than or equal to `N` whose decimal representation, written without leading zeros, uses none of the disliked digits. Input format The first line contains two integers `N` and `k`, denoting the amount that Bob needs to pay and the number of digits that Bob dislikes, respectively. The next line contains `k` space-separated integers denoting the digits that Bob dislikes. When `k` is `0` this line is empty. Output format Print a single integer denoting the minimum amount of money