For 10^n - 1 case: Check if the sum of digits taken n at a time from right is divisible by 999…9 (n digits). If yes then the original number is also divisible by 99…9 (n digits)
Example - Is 6435 divisible by 99 ?
35 + 64 = 99. As per the above rule, 6435 is divisible by 99.
For 10^n + 1 case : Mark off the number in groups of n digits starting from the right, and add the n-digit groups together with alternating signs. If the sum is divisible by 10^n + 1 then the original number is also divisible by 10^n + 1.
Eg: 4512276, (76 + 51) - (22 + 4) = 101, hence divisible by 101
Eg: 9533524, (524 + 9 ) - 533 = 0, hence divisible by 1001.
Now you can try the problem above :)
You can read below articles to learn the complete concepts behinds these types of questions.
Complete set of articles in this topic can be found at