login
Numbers k such that the string 1111k is prime.
1

%I #15 Sep 08 2022 08:45:20

%S 3,7,9,19,21,27,43,49,87,91,151,157,169,181,183,189,211,213,219,247,

%T 259,283,289,301,333,339,351,361,379,393,399,423,427,433,447,457,489,

%U 493,499,531,543,547,553,559,573,577,637,639,651,661,667,673,687,703,711

%N Numbers k such that the string 1111k is prime.

%H Michael De Vlieger, <a href="/A110674/b110674.txt">Table of n, a(n) for n = 1..10000</a>

%e If k=91 then 1111k = 111191 (prime).

%t Select[Range[720], PrimeQ[1111*10^IntegerLength[#] + #] &] (* _Michael De Vlieger_, Jan 22 2018 *)

%o (Magma) [ n: n in [1..1750] | IsPrime(Seqint(Intseq(n) cat [1, 1, 1, 1])) ]; // _Vincenzo Librandi_, Feb 02 2011

%K nonn,base

%O 1,1

%A _Parthasarathy Nambi_, Sep 14 2005