56 lines
1.2 KiB
Markdown
56 lines
1.2 KiB
Markdown
|
---
|
|||
|
id: 5900f3f61000cf542c50ff09
|
|||
|
challengeType: 5
|
|||
|
title: 'Problem 138: Special isosceles triangles'
|
|||
|
videoUrl: ''
|
|||
|
localeTitle: 问题138:特殊的等腰三角形
|
|||
|
---
|
|||
|
|
|||
|
## Description
|
|||
|
<section id="description">考虑具有基本长度,b = 16和腿,L = 17的等腰三角形。 <p>通过使用毕达哥拉斯定理,可以看出三角形的高度h =√(172-82)= 15,比基本长度小1。当b = 272且L = 305时,我们得到h = 273,这比基本长度多一个,这是第二个最小的等腰三角形,具有h = b±1的性质。找到12个最小等腰的ΣL h = b±1且b,L为正整数的三角形。 </p></section>
|
|||
|
|
|||
|
## Instructions
|
|||
|
<section id="instructions">
|
|||
|
</section>
|
|||
|
|
|||
|
## Tests
|
|||
|
<section id='tests'>
|
|||
|
|
|||
|
```yml
|
|||
|
tests:
|
|||
|
- text: <code>euler138()</code>应该返回1118049290473932。
|
|||
|
testString: 'assert.strictEqual(euler138(), 1118049290473932, "<code>euler138()</code> should return 1118049290473932.");'
|
|||
|
|
|||
|
```
|
|||
|
|
|||
|
</section>
|
|||
|
|
|||
|
## Challenge Seed
|
|||
|
<section id='challengeSeed'>
|
|||
|
|
|||
|
<div id='js-seed'>
|
|||
|
|
|||
|
```js
|
|||
|
function euler138() {
|
|||
|
// Good luck!
|
|||
|
return true;
|
|||
|
}
|
|||
|
|
|||
|
euler138();
|
|||
|
|
|||
|
```
|
|||
|
|
|||
|
</div>
|
|||
|
|
|||
|
|
|||
|
|
|||
|
</section>
|
|||
|
|
|||
|
## Solution
|
|||
|
<section id='solution'>
|
|||
|
|
|||
|
```js
|
|||
|
// solution required
|
|||
|
```
|
|||
|
</section>
|