#P2841. A*B Problem
A*B Problem
Description
Given a number , you need to output the smallest number such that the result of contains only digits 0 and 1.
Input Format
A positive integer .
Output Format
The positive integer and the result of , separated by a single space.
6
185 1110
Hint
Sample explanation: .
For 30% of the testdata, . For 50% of the testdata, . For 70% of the testdata, . For 100% of the testdata, .
Translated by ChatGPT 5
京公网安备 11011102002149号