Files
freeCodeCamp/curriculum/challenges/chinese/10-coding-interview-prep/project-euler/problem-254-sums-of-digit-factorials.md
Oliver Eyton-Williams dec409a4bd fix: s/localeTitle/title/g
2020-10-06 23:10:08 +05:30

56 lines
1.2 KiB
Markdown
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

---
id: 5900f46b1000cf542c50ff7d
challengeType: 5
videoUrl: ''
title: 问题254数字因子的总和
---
## Description
<section id="description">将fn定义为n的数字的阶乘的总和。例如f342= 3 + 4 + 2 = 32。 <p>将sfn定义为fn的数字之和。所以sf342= 3 + 2 = 5。 </p><p>将gi定义为最小的正整数n使得sfn= i。虽然sf342是5但sf25也是5并且可以证实g5是25。 </p><p>将sgi定义为gi的数字之和。所以sg5= 2 + 5 = 7。 </p><p>此外可以证实g20是267并且1≤i≤20的Σsgi是156。 </p><p>什么是Σsgi1≤i≤150 </p></section>
## Instructions
<section id="instructions">
</section>
## Tests
<section id='tests'>
```yml
tests:
- text: <code>euler254()</code>应该返回8184523820510。
testString: assert.strictEqual(euler254(), 8184523820510);
```
</section>
## Challenge Seed
<section id='challengeSeed'>
<div id='js-seed'>
```js
function euler254() {
// Good luck!
return true;
}
euler254();
```
</div>
</section>
## Solution
<section id='solution'>
```js
// solution required
```
/section>