3519. Count Numbers with Non-Decreasing Digits
You are given two integers,
landr, represented as strings, and an integerb. Return the count of integers in the inclusive range[l, r]whose digits are in non-decreasing order when represented in baseb.An integer is considered to have non-decreasing digits if, when read from left to right (from the most significant digit to the least significant digit), each digit is greater than or equal to the previous one.
Since the answer may be too large, return it modulo
109 + 7.