# 2022 IMO Problems/Problem 5

## Problem

Find all triples of positive integers with prime and

## Video solution

https://www.youtube.com/watch?v=-AII0ldyDww [Video contains solutions to all day 2 problems]

## Solution

**Case 1:**

- Since is indivisible by , then must also be indivisible by .

- If , then is divisible by , so must be a divisor of , but obviously has no solutions and we ruled out already. For , let's show that there are no solutions using simple inequalities.

- If , then and by throwing away the remaining (non-negative) terms of binomial theorem. For any solution, , which is impossible for . That leaves us with and , but for any integer (proof by induction), so there are no solutions.

- If , RHS is at most and LHS is at least (again from binomial theorem), which gives no solutions as well.

**Case 2:**

- Since is divisible by , then must also be divisible by .

- In addition, RHS is at most , so . We may write , where .

- Since is a divisor of and it must also be a divisor of , so and . We're looking for solutions of .

- Let's factorise : if with odd and , it's

- Since and contain an odd number of odd terms (remember the assumption aka ), they're odd. Also, modulo , so and each following term is even but indivisible by . The highest power of dividing is therefore where is the highest power dividing .

- In comparison, has factors , etc (up to ), and other even factors, so it's divisible at least by . Since for , the only possible solutions have or .

- If , we reuse the inequalities and to show that there are no solutions for .

- Finally, isn't a factorial, and .

**Case 3:**

Just like in case 2, is divisible by so must also be divisible by . However, and are also both divisible by , so remainders modulo tell us that no solutions exist.

**Conclusion:**

The only solutions are .