freeCodeCamp/curriculum/challenges/spanish/08-coding-interview-prep/project-euler/problem-342-the-totient-of-...

1.1 KiB
Raw Blame History

id challengeType title videoUrl localeTitle
5900f4c31000cf542c50ffd5 5 Problem 342: The totient of a square is a cube Problema 342: El totiente de un cuadrado es un cubo.

Description

Considere el número 50. 502 = 2500 = 22 × 54, entonces φ (2500) = 2 × 4 × 53 = 8 × 53 = 23 × 53. 1 Entonces 2500 es un cuadrado y φ (2500) es un cubo.

Encuentre la suma de todos los números n, 1 <n <1010 de manera que φ (n2) sea un cubo.

1 φ denota la función totient de Euler.

Instructions

Tests

tests:
  - text: <code>euler342()</code> debe devolver 5943040885644.
    testString: 'assert.strictEqual(euler342(), 5943040885644, "<code>euler342()</code> should return 5943040885644.");'

Challenge Seed

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

euler342();

Solution

// solution required