Given a number represented as a string or array of digits, rearrange the digits to find the smallest number that is strictly greater than the given number. If no such rearrangement is possible, return…
You've read your 3 free write-ups
Sign up free to keep reading. Your account opens the first 10 questions of every company.