This problem is a programming version of Problem 35 from projecteuler.net
The number, , is called a circular prime because all rotations of the digits: , , and , are themselves prime.
There are thirteen such primes below : . Sum of which is
Find the sum of circular primes that are below ?
Rotations can exceed .
Input contains an integer
Print the answer corresponding to the test case.