Leetcode 866. Prime Palindrome
Find the smallest integer >= n that is both prime and a decimal palindrome. The challenge is to do this efficiently for n up to 1e8 (answer guaranteed ≤ 2·10^8), typically by generating palindromes and performing primality checks rather than brute-force testing every number.
Question Timeline
See when this question was last asked and where, including any notes left by other candidates.
0
Hello Interview Premium
Your account is free and you can post anonymously if you choose.