OFFSET
10,1
COMMENTS
If n is divisible by 3 then one 0 is inserted.
LINKS
Robert Israel, Table of n, a(n) for n = 10..10000
EXAMPLE
a(19) = 100009 because 100009 = 7^2 * 13 * 157 is composite while 109, 1009 and 10009 are all prime.
MAPLE
f:= proc(n) local k, t, i, a, b;
for k from 1 do
for i from ilog10(n) to 1 by -1 do
b:= n mod 10^i;
a:= (n-b)/10^i;
t:= a*10^(k+i)+b;
if not isprime(t) then return t fi;
od od;
end proc:
map(f, [$10 .. 200]);
CROSSREFS
KEYWORD
AUTHOR
Robert Israel, Mar 20 2025
STATUS
approved
