OFFSET
1,2
COMMENTS
For k > 0, numbers k such that the digits 42 followed by k occurrences of the digit 1 is prime (see Example section).
a(24) > 2*10^5.
LINKS
Makoto Kamada, Factorization of near-repdigit-related numbers.
Makoto Kamada, Search for 421w.
EXAMPLE
2 is in this sequence because (379*10^2 - 1)/9 = 4211 is prime.
Initial terms and associated primes:
a(1) = 1, 421;
a(2) = 2, 4211;
a(3) = 5, 4211111;
a(4) = 8; 4211111111;
a(5) = 10, 421111111111; etc.
MATHEMATICA
Select[Range[0, 100000], PrimeQ[(379*10^# - 1)/9] &]
PROG
(PARI) isok(k) = isprime((379*10^k - 1)/9); \\ Michel Marcus, Aug 07 2017
CROSSREFS
KEYWORD
nonn,more,hard
AUTHOR
Robert Price, Aug 06 2017
EXTENSIONS
a(23) from Robert Price, Feb 14 2020
STATUS
approved