Smallest positive integer divisible by and having digit sum equal to some 3-digit number.

353 Views Asked by At

Let $p,q,r$ be distinct digits among $1,2,4,6,8$, and consider the integer $pqr = 100p + 10q + r$. Let $N$ be the smallest positive integer that is divisible by $pqr$ and has digit sum equal to $pqr$. Find $N$.

I've trying to solve it, but cannot find any way to solve it unless use guess and check method. Can anybody show me the way, so I can understand the steps? Thanks