I would compute all ~90 values of 10^N-N. I'm guessing it's hard to divide numbers that big so I'd make a lookup table on multiples of 170. How did I do? This might be overly complicated.
Problem solving
Eli White
Nicholas Sanders
Op here, nobody has the answer yet
Jose Watson
This would have been a non calculator paper for teenagers, comon Veeky Forums really??
Jace Anderson
I told you how to do it you fucking piggot. do the work yourself
David Hill
20, 39, 58, 77, 96
Camden Mitchell
for N from 10 to 99
if ((10^N - N) mod 170 is equal to 0)
print N;
end
end
Ryan King
this but add the digits of 10^N-N instead, takes like 2 lines more
Michael Gomez
good luck computing 10^N - N
Isaiah Miller
This is correct.
#include
void main(void)
{
int n,nines,tens,ones;
for( n=10; n
Nathaniel Lewis
That's a 100 digits number at most, a microwave with a big number maths library will have no problem with it