Find the Smallest Prime Factor of the Quotient ============================================== Another one from YouTube I want to solve without watching the video by the great mathematician Michael Penn: find the smallest prime factor of 2022²⁰²² + 6 ------------ 6 2022 is divisible by 6, and 2022 ---- = 337 6 Great! Now, 2022²⁰²² = 2022×2022²⁰²ⁱ = 6×337×2022²⁰²ⁱ which means that 2022²⁰²² + 6 ------------ = 337×2022²⁰²ⁱ + 1 6 2 and 3 are not factors of this number because 2022 is a multiple of 6, thus 337×2022²⁰²ⁱ + 1 ≡ 1 mod 2 and 337×2022²⁰²ⁱ + 1 ≡ 1 mod 3 The next prime number is 5, and by Fermat's little theorem, if p is a prime and a is a natural number not divisible by p: aᵖ⁻ⁱ ≡ 1 mod p and 2021 = 2020 + 1 = 4 × 505 + 1 which means that 2022²⁰²ⁱ = 2022⁴ˣ⁵⁰⁵⁺ⁱ = 2022×2022⁴ˣ⁵⁰⁵ ≡ 2022×1⁵⁰⁵ mod 5 ≡ 2022×1 mod 5 ≡ 2 mod 5 and 337 = 335 + 2 ≡ 2 mod 5 Thus, 337×2022²⁰²ⁱ + 1 ≡ 2×2 + 1 mod 5 ≡ 0 mod 5 Great! The smallest prime factor of 2022²⁰²² + 6 ------------ 6 is 5