We call a natural number a duodigit if its decimal representation uses no more than two different digits.
For example, , and are duodigits, while is not.
It can be shown that every natural number has duodigit multiples. Let be the smallest (positive) multiple of the number that happens to be a duodigit. For example, , , , and .
Let . You are given , and .
Find . Give your answer in scientific notation rounded to significant digits ( after the decimal point). If, for example, we had asked for instead, the answer format would have been 2.957098800000e7.
Write-up coming later
The complete problem is available here. An approach, code, and answer will be added later.