As reported: Goldman Sachs HackerRank OAs (2025): given a range
[l, r]and an integerq, count the numbers in the range where no digit of the number appears among the digits of its product withq(Analyst, Bangalore); "non-repeating digit in product" — count numbers in a range whose digits and the digits of their product withqare different (Associate, GBM, 120-minute OA).
Given integers l, r and q, count the integers x with l ≤ x ≤ r such that x and x · q have no digit in common (written in base 10, without leading zeros).
Example 1
l = 1, r = 10, q = 2
-> 9 every x from 1 to 9 works (e.g. 7 · 2 = 14); 10 · 2 = 20 shares the digit 0
Example 2
l = 10, r = 20, q = 3
-> 5
Constraints: 1 ≤ l ≤ r ≤ 10^6; 1 ≤ q ≤ 10^3.
Code runner format: one JSON value per line: l, r, q. Implement countDisjointDigits(l, r, q); the harness prints the count.