$a$ is the 1st digit (from the left) of a $3$-digit number $n$. We get the number $m$ by removing a from $n$ and putting it on the right of the unit-digit. For example, the number $123$ becomes $231$.
Find all $n$ such that $m = an$ or $m =\dfrac{n}{a}$
My Work
Let, $b$ be the last two digits.
So, $n = 100a +b$ and $m = 10b +a$
Then, $10b+a = 100a^2 + ab$, or, $10b + a = \dfrac{100a+b}{a}$
The answer will be the number of solutions to this equation. But I don't know how to solve this equation. Any hint will be helpful.
There's probably an elegant proof using divisibility, but in the mean time here's a brute-force solution.
We can re-arrange those equations to give $b$ in terms of $a$, and then just plug the values of $[1, 9]$ into $a$.
$$\begin{align} 10b + a & = 100a^2 + ab\\ 10b - ab & = 100a^2 - a\\ (10 - a)b & = (100a - 1)a\\ b & = \frac{(100a - 1)a}{10 - a}\\ \end{align}$$
and
$$\begin{align} 10ab + a^2 & = 100a+b\\ 10ab - b & = 100a - a^2\\ (10a - 1)b & = (100 - a)a\\ b & = \frac{(100 - a)a}{10a - 1}\\ \end{align}$$
Here's a short Python program that evaluates those two equations for $b$ given $a \in \{1,2,3,4,5,6,7,8,9\}$
output
Hence $a=1, \, b=11 \implies n = m = 111$ is the only solution.
Note that the first equation is monotonically increasing, so if we were doing this by hand we can stop at $a=3$ since for larger $a$ values $b$ will have 3 digits. Similarly, the second equation is monotonically decreasing, so we can stop at $a=4$ since $b$ will only have 1 digit.