# Week 5

Example 1. From a basket of mangoes when counted in twos there was one extra, counted in threes there were two extra, counted in fours there were three extra, counted in fives there were four extra, counted in sixes there were five extra. But counted in sevens there were no extra. At least how many mangoes were there in the basket?

Example 2. Which two-digit number(s) when added to 27 get reversed?

Of course, you can find the solution just below, but it is highly recommended that, you first try to solve it on your own.

Just remember the words of Paul Halmos, who says “the only way to learn mathematics is to do mathematics”.

Solution 1. Let the number of mangoes be n. From the given condition, note the following points:

• When counted in twos there was one extra. This means, when n is divided by 2, it leaves remainder 1.
• When counted in threes there was two extra. This means, when n is divided by 3, it leaves remainder 2.
• When counted in fours there was three extra. This means, when n is divided by 4, it leaves remainder 3.
• When counted in fives there was four extra. This means, when n is divided by 5, it leaves remainder 4.
• When counted in sixes there was five extra. This means, when n is divided by 6, it leaves remainder 5.

The main point to note here is that, the remainder in each case is 1 less than the divisor. This means, (n + 1) must be divisible by 2, 3, 4, 5 and 6. Therefore, (n + 1) is the LCM of 2, 3, 4, 5 and 6. But LCM of 2, 3, 4, 5 and 6 = 60.

The final twist is, when counted in sevens there were no extra. This means, when n is divided by 7, it leaves no remainder (or, n is exactly divisible by 7). It follows that, (n + 1) is either 60 or some multiples of 60 (alternatively, we can say that n = LCM × m – 1, where m is some natural number). The following cases we need to consider:

• Case 1. If n + 1 = 60, then n = 59. But 59 is not divisible by 7, an immediate impossibility.
• Case 2. If n + 1 = 2 × 60, then n = 119. Here, 119 is divisible by 7 and satisfies all the given conditions.

Therefore, the number of mangoes in the basket = 119 = 119.

Solution 2. Consider few two-digit numbers and let’s analyse how they look like:

• 25 = 2 × 10 + 5
• 49 = 4 × 10 + 9
• 73 = 7 × 10 + 3

Therefore, any two-digit number can be written as xy = 10x + y, where x is the ten’s digit and y is the unit digit. If the digits get reversed, the new number takes the form yx = 10y + x. As per the symmetry of the given question,

• 27 + xy = yx
• Or, 27 + (10x + y) = 10y + x
• Or, 27 + 9x = 9y
• Or, 3 + x = y

Needless to say, that x and y are natural numbers satisfying 0 < x, y < 10. For different possibilities regarding x and y, consider the following cases:

• Case 1. Let x = 1. Then y = 4 and 14 is the required number.
• Case 2. Let x = 2. Then y = 5 and 25 is the required number.
• Case 3. Let x = 3. Then y = 6 and 36 is the required number.
• Case 4. Let x = 4. Then y = 7 and 47 is the required number.
• Case 5. Let x = 5. Then y = 8 and 58 is the required number.
• Case 6. Let x = 6. Then y = 9 and 69 is the required number.

No other possibilities and hence 14, 25, 36, 47, 58 and 69 are the only numbers satisfying the given condition.