Files
freeCodeCamp/curriculum/challenges/english/10-coding-interview-prep/project-euler/problem-176-right-angled-triangles-that-share-a-cathetus.md
gikf 32fac23a2d fix(curriculum): clean-up Project Euler 161-180 (#42782)
* fix: clean-up Project Euler 161-180

* fix: corrections from review

Co-authored-by: Tom <20648924+moT01@users.noreply.github.com>

Co-authored-by: Tom <20648924+moT01@users.noreply.github.com>
2021-07-12 16:19:03 +02:00

41 lines
947 B
Markdown

---
id: 5900f41c1000cf542c50ff2f
title: 'Problem 176: Right-angled triangles that share a cathetus'
challengeType: 5
forumTopicId: 301811
dashedName: problem-176-right-angled-triangles-that-share-a-cathetus
---
# --description--
The four right-angled triangles with sides (9,12,15), (12,16,20), (5,12,13) and (12,35,37) all have one of the shorter sides (catheti) equal to 12. It can be shown that no other integer sided right-angled triangle exists with one of the catheti equal to 12.
Find the smallest integer that can be the length of a cathetus of exactly 47547 different integer sided right-angled triangles.
# --hints--
`trianglesSharingCathetus()` should return `96818198400000`.
```js
assert.strictEqual(trianglesSharingCathetus(), 96818198400000);
```
# --seed--
## --seed-contents--
```js
function trianglesSharingCathetus() {
return true;
}
trianglesSharingCathetus();
```
# --solutions--
```js
// solution required
```