OFFSET
1,1
LINKS
Hugo Pfoertner, Table of n, a(n) for n = 1..282
EXAMPLE
a(1) = 3, because s = d(1)-d(3) = 1-2 = -1 is the first negative record.
a(2) = 15, because s = d(1)-d(3)+d(5)-d(7)+d(9)-d(11)+d(13)-d(15) =
1-2+2-2+3-2+2-4 = -2 is the first sum less than -1.
PROG
(PARI) s=0; j=-1; smin=0; forstep(k=1, 600000, 2, j=-j; s=s+j*numdiv(k); if(s<smin, smin=s; print1(k, ", ")))
CROSSREFS
KEYWORD
nonn
AUTHOR
Hugo Pfoertner, Sep 08 2018
STATUS
approved