freeCodeCamp/curriculum/challenges/spanish/08-coding-interview-prep/project-euler/problem-381-prime-k-factori...

56 lines
1.1 KiB
Markdown
Raw Normal View History

2018-10-08 17:34:43 +00:00
---
2018-10-10 20:20:40 +00:00
id: 5900f4ea1000cf542c50fffc
2018-10-08 17:34:43 +00:00
challengeType: 5
title: 'Problem 381: (prime-k) factorial'
2018-10-10 20:20:40 +00:00
videoUrl: ''
localeTitle: 'Problema 381: factorial (prime-k)'
2018-10-08 17:34:43 +00:00
---
## Description
2018-10-10 20:20:40 +00:00
<section id="description"> Para una cebada p, deje que S (p) = (∑ (pk)!) Mod (p) para 1 ≤ k ≤ 5. <p> Por ejemplo, si p = 7, (7-1)! + (7-2)! + (7-3)! + (7-4)! + (7-5)! = 6! + 5! + 4! + 3! + 2! = 720 + 120 + 24 + 6 + 2 = 872. Como 872 mod (7) = 4, S (7) = 4. </p><p> Se puede verificar que ∑S (p) = 480 para 5 ≤ p &lt;100. </p><p> Encuentre ∑S (p) para 5 ≤ p &lt;108. </p></section>
2018-10-08 17:34:43 +00:00
## Instructions
2018-10-10 20:20:40 +00:00
<section id="instructions">
2018-10-08 17:34:43 +00:00
</section>
## Tests
<section id='tests'>
```yml
tests:
- text: <code>euler381()</code> debe devolver 139602943319822.
testString: 'assert.strictEqual(euler381(), 139602943319822, "<code>euler381()</code> should return 139602943319822.");'
```
</section>
## Challenge Seed
<section id='challengeSeed'>
<div id='js-seed'>
```js
function euler381() {
// Good luck!
return true;
}
euler381();
2018-10-10 20:20:40 +00:00
2018-10-08 17:34:43 +00:00
```
</div>
</section>
## Solution
<section id='solution'>
```js
// solution required
```
</section>