login
Primes of the form n (written in base 10) followed by n 1's.
4

%I #8 Jun 08 2021 18:01:29

%S 11,211,511111,71111111,101111111111,161111111111111111,

%T 2011111111111111111111,

%U 6511111111111111111111111111111111111111111111111111111111111111111

%N Primes of the form n (written in base 10) followed by n 1's.

%t Do[p = FromDigits[ Join[ IntegerDigits[n], IntegerDigits[(10^n - 1)/9]]]; If[ PrimeQ[p], Print[p]], {n, 1, 100}]

%t Select[Table[FromDigits[Join[IntegerDigits[n],PadRight[{},n,1]]],{n,100}],PrimeQ] (* _Harvey P. Dale_, Jun 08 2021 *)

%Y Cf. A068817 (for values of n).

%K base,nonn

%O 1,1

%A _Amarnath Murthy_, May 02 2002

%E More terms from _Vladeta Jovovic_ and _Robert G. Wilson v_, May 03 2002