In math class Ivica was told to add up every divisor of 100. The answer is f(100)=1+2+4+5+10+20+25+50+100=217.
He finished that far too quickly, so he got a new assignment: for every natural number from L to R, inclusive, compute the sum of its divisors, then add all of those sums together. Ivica is busy with other things and has no time for the arithmetic, so compute the value for him.
Write f(n) for the sum of the divisors of a natural number n. You need f(L)+f(L+1)+⋯+f(R).