3456.
You are given two integers lo and hi. Return every staircase number in the range [lo, hi], both ends included, in increasing order.lo=40, hi=80 → [45, 56, 67, 78]
In this range the digits climb step by step in 45, 56, 67 and 78.
lo=780, hi=2300 → [789, 1234]
The three-digit 789 and the four-digit 1234 fit; the next one, 2345, is already above 2300.
lo=90, hi=99 → []
No digit follows 9, and 89 is below 90, so there are no such numbers.
lo ≤ hi ≤ 10⁹lo=40, hi=80
[45, 56, 67, 78]
Run checks the first 3 tests in your browser. Submit checks all 88 tests on the server, hidden ones included.