Files
gikf eef1805fe6 fix(curriculum): clean-up Project Euler 201-220 (#42826)
* fix: clean-up Project Euler 201-220

* 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-15 09:20:31 +02:00

47 lines
931 B
Markdown
Raw Permalink 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: 5900f43e1000cf542c50ff50
title: 'Problem 210: Obtuse Angled Triangles'
challengeType: 5
forumTopicId: 301852
dashedName: problem-210-obtuse-angled-triangles
---
# --description--
Consider the set $S(r)$ of points ($x$,$y$) with integer coordinates satisfying $|x| + |y| ≤ r$.
Let $O$ be the point (0,0) and $C$ the point ($\frac{r}{4}$,$\frac{r}{4}$).
Let $N(r)$ be the number of points $B$ in $S(r)$, so that the triangle $OBC$ has an obtuse angle, i.e. the largest angle $α$ satisfies $90°&lt;α&lt;180°$.
So, for example, $N(4)=24$ and $N(8)=100$.
What is $N(1\\,000\\,000\\,000)$?
# --hints--
`obtuseAngledTriangles()` should return `1598174770174689500`.
```js
assert.strictEqual(obtuseAngledTriangles(), 1598174770174689500);
```
# --seed--
## --seed-contents--
```js
function obtuseAngledTriangles() {
return true;
}
obtuseAngledTriangles();
```
# --solutions--
```js
// solution required
```