Math Puzzle: Prime Time

Find one million consecutive positive numbers, none of which are prime.

Ancient math tells us that prime numbers (2, 3, 5, 7, 11, ...,), which have no factors except for 1 and themselves, go on forever, but more modern math adds that primes become rarer as numbers grow larger. In fact, there’s no limit on how far apart successive prime numbers can be. Your task is to construct a specific example of one million nonprime numbers in a row.

If a number is divisible by 2, then adding 2 to it produces another number divisible by 2. Likewise, if a number is divisible by 3, then adding 3 to it produces another number divisible by 3. Try to extend this observation.

We’ll start by finding 10 consecutive nonprime numbers, and the method will readily extend to a million.

If a number is divisible by 2, then adding 2 to it produces another number divisible by 2. Likewise, if a number is divisible by 3, then adding 3 to it produces another number divisible by 3. So if we start with a number that is divisible by 10 consecutive numbers, then we can add each of those numbers to it to produce 10 consecutive nonprime numbers.

Consider multiplying the first 11 numbers together: 1 × 2 × 3 × 4 × 5 × 6 × 7 × 8 × 9 × 10 × 11. This is known as 11 factorial (written 11!). By design, it is divisible by every number from 2 to 11 (10 consecutive numbers). So 11! + 2 is divisible by 2, 11! + 3 is divisible by 3, 11! + 4 is divisible by 4, and so on, up through 11! + 11. We’ve found 10 consecutive nonprime numbers. Note that if we began with 10! rather than 11!, we would have only guaranteed nine consecutive nonprimes.

The same trick works for a million: 2 to 1,000,001 form a million consecutive numbers, and 1,000,001! is divisible by all of them. So our answer is:

1,000,001! + 2, 1,000,001! + 3, 1,000,001! + 4, ..., 1,000,001! + 1,000,001

We’d love to hear from you! E-mail us at games@sciam.com to share your experience.

0