OFFSET
1,1
EXAMPLE
The first seven deficient numbers sum to 1 + 2 + 3 + 4 + 5 + 7 + 8 = 30 and the first two abundant numbers sum to 12 + 18 = 30.
The sum of first 113 deficient numbers and the sum of first 61 abundant numbers are equal to 8388.
MAPLE
with(numtheory): P:=proc(q) local a, b, c, d, n; a:=0; b:=0; c:=0; d:=0;
for n from 1 to q do b:=b+1; while sigma(b)<=2*b do b:=b+1; od; a:=a+b;
while c<a do d:=d+1; if sigma(d)<2*d then c:=c+d; fi; od;
if c=a then print(a); fi; od; end: P(10^9);
CROSSREFS
KEYWORD
nonn,more
AUTHOR
Paolo P. Lava, Feb 26 2018
EXTENSIONS
a(6)-a(8) from Giovanni Resta, Feb 26 2018
STATUS
approved