A056728 Palindromic primes using only two distinct digits and only the exterior digit is different.
101, 131, 151, 181, 191, 313, 353, 373, 383, 727, 757, 787, 797, 919, 929, 13331, 15551, 16661, 19991, 72227, 75557, 76667, 78887, 79997, 1333331, 1444441, 1777771, 3222223, 3444443, 7666667, 9222229, 9888889
Offset: 1
Links
- Robert Israel, Table of n, a(n) for n = 1..127
- Patrick De Geest, PDP Reference Table.
- Makoto Kamada, Plateau and depression numbers of the form ABB...BBA.
Programs
-
Maple
f:= (a,b,n) -> a*(10^n + 1) + b*(10^n - 10)/9: select(isprime,[seq(seq(seq(f(a,b,n),b={$0..9} minus {a}),a=1..9),n=2..8)]); # Robert Israel, Nov 02 2014
-
Mathematica
Select[Union[Flatten[Table[FromDigits[Join[{a},PadRight[{},n,b],{a}]],{n,1,7,2},{b,0,9},{a,{1,3,7,9}}]]],PrimeQ] (* Harvey P. Dale, Mar 07 2015 *)
Extensions
Links added by Patrick De Geest, Nov 02 2014
Comments