Primey Palindromes V2

This problem is a slightly harder version of Primey Palindromes.

Let \( f(x) \) be the sum of the digits of \(x\).
Let \(g(n) \) be the number of \(n\) digit palindromes \(a\) such that
- \(a\) is prime,
- \(a + f(a) \) is also prime.

What is the smallest value of \(n > 2 \) such that \(g(n) \) is not 0 and not prime?

Example
- \(383\) is a prime palindrome.
- \(f(383) = 3+8+3=14 \).
- \(383+f(383)=397\) which is also prime.

×

Problem Loading...

Note Loading...

Set Loading...