28 lines
683 B
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: 5900f39e1000cf542c50feb1
title: 问题50连续的总和
challengeType: 5
videoUrl: ''
---
# --description--
素数41可以写成六个连续素数的总和41 = 2 + 3 + 5 + 7 + 11 + 13这是连续素数的最长和它加到低于一百的素数。连续素数低于1000的连续素数加上一个素数包含21个项等于953.哪个素数低于一百万,可以写成最连续素数的总和?
# --hints--
`consecutivePrimeSum(1000)`应该返回953。
```js
assert.strictEqual(consecutivePrimeSum(1000), 953);
```
`consecutivePrimeSum(1000000)`应该返回997651。
```js
assert.strictEqual(consecutivePrimeSum(1000000), 997651);
```
# --solutions--