A superprime is an integer such that all its left-to-right initial segments are prime (e.g. 7331 whose segments are 7, 73, 733, and 7331, all prime).
There is a largest superprime.
Source: USA Computing Olympiad,
(In reply to Another method.
this is also similar to project euler problem 37 in which primes that are both left and right truncatable are sought.
The code I used for this problem was simply the code from the first part of my solution to the project euler problem.
Posted by Daniel
on 2010-10-20 12:50:37