OFFSET
1,1
EXAMPLE
If k = 10, then k333333 = 10333333 (prime);
if k = 58, then k333333 = 58333333 (prime);
if k = 100, then k333333 = 100333333 (prime).
MAPLE
q:= n-> isprime(parse(cat(n, 3$6))):
select(q, [$1..512])[]; # Alois P. Heinz, Oct 29 2021
MATHEMATICA
Select[Range[550], PrimeQ[FromDigits[Join[IntegerDigits[#], {3, 3, 3, 3, 3, 3}]]]&] (* Harvey P. Dale, Apr 13 2012 *)
PROG
(Magma) [ n: n in [1..700] | IsPrime(Seqint([3, 3, 3, 3, 3, 3] cat Intseq(n))) ]; // Vincenzo Librandi, Feb 04 2011
(PARI) is(n)=isprime(n*10^6+333333) \\ Charles R Greathouse IV, May 15 2013
(Python)
from sympy import isprime
def aupto(limit):
return [k for k in range(limit+1) if isprime(int(str(k) + "333333"))]
print(aupto(512)) # Michael S. Branicky, Oct 29 2021
CROSSREFS
KEYWORD
base,nonn
AUTHOR
Parthasarathy Nambi, Feb 24 2005
STATUS
approved