2018-09-30 23:01:58 +01:00
---
id: 5900f3ef1000cf542c50ff02
title: 'Problem 131: Prime cube partnership'
2020-11-27 19:02:05 +01:00
challengeType: 5
2019-08-05 09:17:33 -07:00
forumTopicId: 301759
2018-09-30 23:01:58 +01:00
---
2020-11-27 19:02:05 +01:00
# --description--
2018-09-30 23:01:58 +01:00
There are some prime values, p, for which there exists a positive integer, n, such that the expression n3 + n2p is a perfect cube.
2020-11-27 19:02:05 +01:00
2018-09-30 23:01:58 +01:00
For example, when p = 19, 83 + 82× 19 = 123.
2020-11-27 19:02:05 +01:00
What is perhaps most surprising is that for each prime with this property the value of n is unique, and there are only four such primes below one-hundred.
2018-09-30 23:01:58 +01:00
2020-11-27 19:02:05 +01:00
How many primes below one million have this remarkable property?
2018-09-30 23:01:58 +01:00
2020-11-27 19:02:05 +01:00
# --hints--
2018-09-30 23:01:58 +01:00
2020-11-27 19:02:05 +01:00
`euler131()` should return 173.
2018-09-30 23:01:58 +01:00
2020-11-27 19:02:05 +01:00
```js
assert.strictEqual(euler131(), 173);
2018-09-30 23:01:58 +01:00
```
2020-11-27 19:02:05 +01:00
# --seed--
2018-09-30 23:01:58 +01:00
2020-11-27 19:02:05 +01:00
## --seed-contents--
2018-09-30 23:01:58 +01:00
```js
function euler131() {
2020-09-15 09:57:40 -07:00
2018-09-30 23:01:58 +01:00
return true;
}
euler131();
```
2020-11-27 19:02:05 +01:00
# --solutions--
2018-09-30 23:01:58 +01:00
```js
// solution required
```