2018-09-30 22:01:58 +00:00
---
id: 5900f4461000cf542c50ff59
title: 'Problem 218: Perfect right-angled triangles'
2020-11-27 18:02:05 +00:00
challengeType: 5
2019-08-05 16:17:33 +00:00
forumTopicId: 301860
2021-01-13 02:31:00 +00:00
dashedName: problem-218-perfect-right-angled-triangles
2018-09-30 22:01:58 +00:00
---
2020-11-27 18:02:05 +00:00
# --description--
2018-09-30 22:01:58 +00:00
Consider the right angled triangle with sides a=7, b=24 and c=25.
2020-11-27 18:02:05 +00:00
2018-09-30 22:01:58 +00:00
The area of this triangle is 84, which is divisible by the perfect numbers 6 and 28.
2020-11-27 18:02:05 +00:00
2018-09-30 22:01:58 +00:00
Moreover it is a primitive right angled triangle as gcd(a,b)=1 and gcd(b,c)=1.
2020-11-27 18:02:05 +00:00
Also c is a perfect square.
2018-09-30 22:01:58 +00:00
2020-11-27 18:02:05 +00:00
We will call a right angled triangle perfect if -it is a primitive right angled triangle -its hypotenuse is a perfect square
2018-09-30 22:01:58 +00:00
2020-11-27 18:02:05 +00:00
We will call a right angled triangle super-perfect if -it is a perfect right angled triangle and -its area is a multiple of the perfect numbers 6 and 28.
2018-09-30 22:01:58 +00:00
How many perfect right-angled triangles with c≤1016 exist that are not super-perfect?
2020-11-27 18:02:05 +00:00
# --hints--
2018-09-30 22:01:58 +00:00
2020-11-27 18:02:05 +00:00
`euler218()` should return 0.
2018-09-30 22:01:58 +00:00
2020-11-27 18:02:05 +00:00
```js
assert.strictEqual(euler218(), 0);
2018-09-30 22:01:58 +00:00
```
2020-11-27 18:02:05 +00:00
# --seed--
2018-09-30 22:01:58 +00:00
2020-11-27 18:02:05 +00:00
## --seed-contents--
2018-09-30 22:01:58 +00:00
```js
function euler218() {
2020-09-15 16:57:40 +00:00
2018-09-30 22:01:58 +00:00
return true;
}
euler218();
```
2020-11-27 18:02:05 +00:00
# --solutions--
2018-09-30 22:01:58 +00:00
```js
// solution required
```