login
A385957
Prime(n) is the a(n)-th prime having its distinct digits.
1
1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 1, 1, 1, 1, 1, 1, 1, 1, 2, 2, 1, 1, 1, 2, 1, 1, 1, 1, 3, 1, 4, 1, 1, 1, 1, 1, 1, 1, 2, 1, 1, 2, 2, 2, 3, 1, 2, 1, 2, 3, 1, 1, 1, 1, 1, 1, 2, 2, 1, 1, 2, 1, 5, 6, 3, 7, 3, 1, 1, 2, 1, 1, 4, 1, 2, 1, 2, 1, 1, 2, 2, 1, 2, 2, 3, 1, 1
OFFSET
1,11
LINKS
David A. Corneth, PARI program
Michael De Vlieger, Scatterplot of a(n), n = 1..10^6.
EXAMPLE
a(1) = 1 as prime(1) = 2 is the first prime having its distinct digits {2}.
a(11) = 2 as prime(11) = 31 is the second prime having its disitinct digits {1, 3} (the first is 13).
a(32) = 4 as prime(32) = 131 is the fourth prime having its distinct digits {1, 3} (the first three are 13, 31 and 113).
MATHEMATICA
Block[{c, f, p}, c[_] := 0; f[x_] := Union@ IntegerDigits[x]; Reap[Do[p = Prime[n]; Sow[++c[f[p] ] ], {n, 120}] ][[-1, 1]] ] (* Michael De Vlieger, Jul 13 2025 *)
PROG
(PARI) \\ See Corneth link
CROSSREFS
KEYWORD
nonn,easy,base,look
AUTHOR
David A. Corneth, Jul 13 2025
STATUS
approved