OFFSET
1,1
LINKS
Robert Israel, Table of n, a(n) for n = 1..10000
EXAMPLE
a(2) = 5 is a term because A255217(5) = 2*3*5*7*11 mod (2+3+5+7+11) = 14 divides 2+3+5+7+11 = 28.
MAPLE
P:= 1: S:= 0: p:= 1:
count:= 0: R:= NULL:
for n from 1 while count < 100 do
p:= nextprime(p);
P:= P*p; S:= S+p;
r:= P mod S;
if r = 0 then next fi;
v:= S mod r;
if v = 0 then
count:= count+1; R:= R, n;
fi
od:
R;
MATHEMATICA
Select[Range[1000], (m = Mod[Times @@ (p = Prime[Range[#]]), Plus @@ p]) > 0 && Divisible[Plus @@ p, m] &] (* Amiram Eldar, Nov 28 2021 *)
CROSSREFS
KEYWORD
nonn
AUTHOR
J. M. Bergot and Robert Israel, Nov 28 2021
STATUS
approved