freeCodeCamp/curriculum/challenges/english/08-coding-interview-prep/project-euler/problem-401-sum-of-squares-of-divisors.english.md
Valeriy 79d9012432 fix(curriculum): quotes in tests (#18828)
* fix(curriculum): tests quotes

* fix(curriculum): fill seed-teardown

* fix(curriculum): fix tests and remove unneeded seed-teardown
2018-10-20 23:32:47 +05:30

1.0 KiB

id, challengeType, title
id challengeType title
5900f4fd1000cf542c51000f 5 Problem 401: Sum of squares of divisors

Description

The divisors of 6 are 1,2,3 and 6. The sum of the squares of these numbers is 1+4+9+36=50.

Let sigma2(n) represent the sum of the squares of the divisors of n. Thus sigma2(6)=50.

Let SIGMA2 represent the summatory function of sigma2, that is SIGMA2(n)=∑sigma2(i) for i=1 to n. The first 6 values of SIGMA2 are: 1,6,16,37,63 and 113.

Find SIGMA2(1015) modulo 109.

Instructions

Tests

tests:
  - text: <code>euler401()</code> should return 281632621.
    testString: assert.strictEqual(euler401(), 281632621, '<code>euler401()</code> should return 281632621.');

Challenge Seed

function euler401() {
  // Good luck!
  return true;
}

euler401();

Solution

// solution required