OFFSET
1,2
COMMENTS
From the first 3000 primes, only 289 are such that n, p[n], p[n]+n, p[n]-n and p[n]*n all are 4-less.
LINKS
Robert Israel, Table of n, a(n) for n = 1..10000
MAPLE
fourless:= n -> not has(4, convert(n, base, 10)):
p:= 1: R:= NULL: count:= 0:
for n from 1 while count < 100 do
p:= nextprime(p);
if andmap(fourless, [n, p, p+n, p-n, p*n]) then
count:= count+1; R:= R, n;
fi
od:
R; # Robert Israel, Apr 23 2020
MATHEMATICA
id[x_]:=IntegerDigits[x]; pr[i_]:=Prime[i]; ra=Range[3000]; A104424=Select[ra, Position[Union[id[ # ], id[pr[ # ]], id[pr[ # ]+# ], id[pr[ # ]-# ], id[pr[ # ]*# ]], 4]=={}&]
Select[Range[350], Count[Flatten[IntegerDigits/@{#, Prime[#], Prime[ #]+#, Prime[ #]-#, Prime[ #]#}], 4]==0&] (* Harvey P. Dale, Apr 13 2022 *)
CROSSREFS
KEYWORD
nonn,base
AUTHOR
Zak Seidov, Mar 07 2005
EXTENSIONS
Name edited by Robert Israel, Apr 23 2020
STATUS
approved