Suppose you have a number $n^m$. Is there a way to figure out how many 1s it contains "easily"? For large numbers, this probably means you do this without computing the value. What about 2s, or other digits?
Are there specific values of n, m for which you can (e.g. n is prime)?
This question arose when I was working on a recreational maths problem. At one point it was necessary to count how many 1s there are in a large prime power but I could not see how to do this without a calculator.