# Prime number where all (ordered) combinations of digits are prime

Are there any prime numbers with more than two digits such that all combinations of its digits (preserving order) are prime? For example, if the number abc is prime, then a, b, and c are prime, and so are ab, ac, and bc.

What is the largest such number, or the largest known? I'm not even sure this is possible, but I imagine the probability of a prime passing this test gets really small really fast as you start adding digits...

• @joriki 33 is not prime. – John Douma Sep 14 '15 at 17:23
• @John: oops :-) – joriki Sep 14 '15 at 17:23
• I plan on making a script to check, I just though someone else might have fun with this question too. I wonder if you can prove something general about this... – Engineero Sep 14 '15 at 17:25
• For 3 digits, there are none. – John Douma Sep 14 '15 at 17:25

There is no such number. All digits except the first would have to be $3$, $7$ or $9$, since $1$ is not a prime and the remaining digits cannot be the last digits of primes with more than one digit. It cannot contain the same digit twice, since that would yield a number divisible by $11$. It also can't contain $39$ or $93$, which are divisible by $3$. That leaves only $37$, $73$, $97$ and $79$, preceded by one prime digit other than $3$ or $7$, i.e. $2$ or $5$. None of the eight resulting numbers is prime.
• a) The question asked for numbers with more than two digits, so $73$ isn't one. b) The fact that that OEIS list is finite doesn't mean that there are finitely many such numbers. The entry itself says that the linked list of $200$ numbers only goes up to $10^{13}$. In response to this question I estimated that we should expect there to be about $2000$ such numbers, of which roughly half should be expected to have $74$ digits or more. – joriki Sep 14 '15 at 17:41