Problem 738 · Medium

Monotone Increasing Digits

Find the largest number not above a given value whose digits never decrease from left to right. The visual finds the first drop and reduces the digit before it.

Open the interactive visualisation