OFFSET
1,1
LINKS
Harvey P. Dale, Table of n, a(n) for n = 1..1000
EXAMPLE
When divided by 2,3,5,7,11,...., the number 211 gives remainders 1,1,1,1,2, etc., which sum to 1615 and the number 223 gives remainders 1,1,3,6,3, etc., which sum to 1573. 1573 is smaller than 1615, so 223 is in the sequence.
MATHEMATICA
Prime[#]&/@(Flatten[Position[Differences[Table[Total[Mod[p, Prime[Range[PrimePi[p]]]]], {p, Prime[Range[600]]}]], _?(#<0&)]]+1) (* Harvey P. Dale, Jul 18 2025 *)
CROSSREFS
KEYWORD
nonn
AUTHOR
Neil Fernandez, Sep 01 2008
STATUS
approved
