Primes p > 3 and 24's Secret
Why is p squared minus one divisible by twenty four is a medium quant interview question on Pure Math.
This question centers on a simple-looking number theory claim involving primes and a quadratic expression in the prime. The candidate is asked to reason about why a particular algebraic expression built from a prime greater than a small bound must always be divisible by a fixed integer. The heart of the setup is the interaction between primality, small moduli, and factorization of polynomial-like expressions in the prime. It is a classic pure mathematics interview question, often used in quantitative and trading roles to see how well someone can turn an elementary statement into a clean, structured argument.
The solution leans heavily on modular arithmetic, factorization into linear factors, and a careful analysis of congruence classes. An interviewer is watching for recognition that primality imposes strong restrictions modulo small bases, and for the ability to translate those restrictions into properties of the factors of the expression. They also look for clarity in splitting the problem into cases, precise use of divisibility language, and avoidance of handwaving. Strong candidates usually generalize or rephrase the argument in terms of broader patterns in modular arithmetic and number theory.
What it tests
When analyzing divisibility properties of expressions involving integers, especially those constrained by primality, it is crucial to exploit the structural consequences of being coprime to small moduli. For primes greater than 3, their exclusion from divisibility by 2 and 3 forces them into specific congruence classes modulo 6. This, in turn, shapes the factors of related expressions like $p^2-1$, which can be decomposed into $(p-1)(p+1)$—two consecutive even numbers, and numbers adjacent to a multiple of 3. The interplay between these congruence classes ensures that certain products accumulate all the necessary small prime factors, guaranteeing divisibility by their product. This pattern holds because the arithmetic structure of the integers, combined with the constraints of primality, leaves only a limited set of possibilities for $p$, each forcing the desired divisibility.
Practise this question with written feedback, or hear it in a spoken mock interview.
Get started free