56 lines
1.0 KiB
Markdown
56 lines
1.0 KiB
Markdown
|
---
|
|||
|
id: 5900f3d91000cf542c50feeb
|
|||
|
challengeType: 5
|
|||
|
title: 'Problem 108: Diophantine Reciprocals I'
|
|||
|
videoUrl: ''
|
|||
|
localeTitle: 问题108:丢番图互惠I
|
|||
|
---
|
|||
|
|
|||
|
## Description
|
|||
|
<section id="description">在下面的等式中,x,y和n是正整数。 1 / <var>x</var> + 1 / <var>y</var> = 1 / <var>n</var>对于<var>n</var> = 4,恰好有三种不同的解:1/5 + 1/20 = 1/4 <br> 1/6 + 1/12 = 1/4 <br> 1/8 + 1/8 = 1/4不同解的数量超过一千的<var>n的</var>最小值是多少? </section>
|
|||
|
|
|||
|
## Instructions
|
|||
|
<section id="instructions">
|
|||
|
</section>
|
|||
|
|
|||
|
## Tests
|
|||
|
<section id='tests'>
|
|||
|
|
|||
|
```yml
|
|||
|
tests:
|
|||
|
- text: diophantineOne <code>diophantineOne()</code>应返回180180。
|
|||
|
testString: 'assert.strictEqual(diophantineOne(), 180180, "<code>diophantineOne()</code> should return 180180.");'
|
|||
|
|
|||
|
```
|
|||
|
|
|||
|
</section>
|
|||
|
|
|||
|
## Challenge Seed
|
|||
|
<section id='challengeSeed'>
|
|||
|
|
|||
|
<div id='js-seed'>
|
|||
|
|
|||
|
```js
|
|||
|
function diophantineOne() {
|
|||
|
// Good luck!
|
|||
|
return true;
|
|||
|
}
|
|||
|
|
|||
|
diophantineOne();
|
|||
|
|
|||
|
```
|
|||
|
|
|||
|
</div>
|
|||
|
|
|||
|
|
|||
|
|
|||
|
</section>
|
|||
|
|
|||
|
## Solution
|
|||
|
<section id='solution'>
|
|||
|
|
|||
|
```js
|
|||
|
// solution required
|
|||
|
```
|
|||
|
</section>
|