# Q. A number N is formed by writing 9 for 99 times. What is the remainder if N is divided by 13?

(a) 11

(b) 9

(c) 7

(d) 1

Correct Answer: (a) 11

#### Question from UPSC Prelims 2023 CSAT

**Explanation : **

## Number n is formed by writing 9 for 99 times

Group the given number into sets of 3 starting from the right, or the units place. From the rightmost group of 3 digits apply the subtraction and addition operations alternatively and find the result. If the result is either a 0 or it can be divided by 13 completely without leaving a remainder, then the number is divisible by 13.

For example, in the number 1,139,502 applying the subtraction and addition operations alternatively from the rightmost group of 3 digits, we get 502 – 139 + 1 = 364. 364/13 gives 28 as quotient and 0 as remainder. Therefore, 1139502 is divisible by 13.

Similarly,

### To determine if the number formed by writing the digit 9 ninety-nine times is divisible by 13

We can use a method that involves grouping the digits and applying alternating addition and subtraction operations. Here’s a step-by-step explanation:

**1. Form the Number**

The number in question is composed of the digit 9 repeated 99 times.

**2. Group the Digits**

We group the digits into sets of three, starting from the rightmost digit. This results in 33 groups of ‘999’.

**3. Apply Operations**

Starting from the rightmost group, we apply alternating subtraction and addition operations to these groups. This method is based on a divisibility rule for 13, which states that if you take the last three digits of a number, subtract the next three digits, add the next three, and so on, and if the resulting number is divisible by 13, then the original number is also divisible by 13.

**4. Calculate**

For our number, the calculation would look like this:

**999 – 999 + 999 – 999 + … + 999** (33 times in total).

**5. Simplify the Calculation**

Since each ‘999’ is either added or subtracted, and there are an odd number of these groups (33), the calculation simplifies to just one ‘999’ (because 32 of them will cancel each other out).

**6. Check Divisibility**

Now, we check if 999 is divisible by 13:

**999 ÷ 13 = 76 remainder 11**.

Since there is a remainder when 999 is divided by 13, the original number (composed of 99 nines) is not divisible by 13.