30:00
You are given two integers n and t.
n
t
Return the smallest number greater than or equal to n such that the product of its digits is divisible by t.
1≤n≤1001 \leq n \leq 1001≤n≤100
1≤t≤101 \leq t \leq 101≤t≤10
Run code to see results.
Start at x = n = 10 and count upward until the product of x's digits is a multiple of t = 2.
n = 10, t = 2, candidate x = n + 0
p = product of digits
Given n and t, return the smallest number at least n whose digit product is a multiple of t.