1.0 KiB
1.0 KiB
id | challengeType | title |
---|---|---|
5900f4f91000cf542c51000c | 5 | Problem 397: Triangle on parabola |
Description
Let F(K, X) be the number of the integer quadruplets (k, a, b, c) such that at least one angle of the triangle ABC is 45-degree, with 1 ≤ k ≤ K and -X ≤ a < b < c ≤ X.
For example, F(1, 10) = 41 and F(10, 100) = 12492. Find F(106, 109).
Instructions
Tests
tests:
- text: <code>euler397()</code> should return 141630459461893730.
testString: assert.strictEqual(euler397(), 141630459461893730, '<code>euler397()</code> should return 141630459461893730.');
Challenge Seed
function euler397() {
// Good luck!
return true;
}
euler397();
Solution
// solution required