freeCodeCamp/curriculum/challenges/chinese/08-coding-interview-prep/project-euler/problem-125-palindromic-sum...

56 lines
1.1 KiB
Markdown
Raw Normal View History

---
id: 5900f3e91000cf542c50fefc
challengeType: 5
title: 'Problem 125: Palindromic sums'
videoUrl: ''
localeTitle: 问题125回文总和
---
## Description
<section id="description">回文数595很有意思因为它可以写成连续正方形的总和62 + 72 + 82 + 92 + 102 + 112 + 122.正好有11个以下的回文可以写成连续的平方和并且这些回文的总和是4164.注意没有包括1 = 02 + 12因为该问题涉及正整数的平方。找到小于108的所有数字的总和这些数字都是回文并且可以写为连续正方形的总和。 </section>
## Instructions
<section id="instructions">
</section>
## Tests
<section id='tests'>
```yml
tests:
- text: <code>euler125()</code>应该返回2906969179。
testString: 'assert.strictEqual(euler125(), 2906969179, "<code>euler125()</code> should return 2906969179.");'
```
</section>
## Challenge Seed
<section id='challengeSeed'>
<div id='js-seed'>
```js
function euler125() {
// Good luck!
return true;
}
euler125();
```
</div>
</section>
## Solution
<section id='solution'>
```js
// solution required
```
</section>