OFFSET
1,1
LINKS
Robert Israel, Table of n, a(n) for n = 1..10000
EXAMPLE
n=5: 2+3+5+7+11 <= 29 = a(5).
MAPLE
P:= [seq(ithprime(i), i=1..100)]:
S:= ListTools:-PartialSums(P):
map(s -> nextprime(s-1), S); # Robert Israel, Jul 04 2019
MATHEMATICA
If[PrimeQ[#], #, NextPrime[#]]&/@Accumulate[Prime[Range[50]]] (* Harvey P. Dale, Feb 04 2011 *)
CROSSREFS
KEYWORD
nonn
AUTHOR
Reinhard Zumkeller, Nov 27 2002
STATUS
approved