2014 AIME II Problem 15
Problem 15 of 15HarderAlgebraNumber TheoryArithmeticProblem-Solving Techniques
For any integer let be the smallest prime which does not divide Define the integer function to be the product of all primes less than if and if Let be the sequence defined by and for Find the smallest positive integer such that
Your answer
Integer from 0 to 999
Show solution
Solution
List the primes in order as Every is squarefree, so it is described by the set of primes dividing it, and we claim this set encodes in binary: if with then
Indeed, suppose and let be the smallest index with Then and is exactly the product of the primes for the trailing -bits (with when ). So removes the trailing ones and inserts — precisely adding in binary. Since corresponds to induction proves the claim.
Now which corresponds to binary digits at positions Hence
Tagged: prime · number base · recursion · pattern recognition