A052016 Primes with digits in descending order that differ exactly by 1.
2, 3, 5, 7, 43, 76543
Offset: 1
Programs
-
Mathematica
fQ[n_]:=Module[{id=IntegerDigits[n],}, n < 10 || Union[Differences[id]] == {-1}]; Select[Prime[Range[10000]], fQ] (* Vladimir Joseph Stephan Orlovsky, Dec 29 2010 *)
Comments