Files
gikf a2b2ef3f75 fix(curriculum): clean-up Project Euler 441-460 (#43068)
* fix: clean-up Project Euler 441-460

* 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-30 08:20:31 -07:00

1.3 KiB

id, title, challengeType, forumTopicId, dashedName
id title challengeType forumTopicId dashedName
5900f5311000cf542c510044 Problem 453: Lattice Quadrilaterals 5 302126 problem-453-lattice-quadrilaterals

--description--

A simple quadrilateral is a polygon that has four distinct vertices, has no straight angles and does not self-intersect.

Let Q(m, n) be the number of simple quadrilaterals whose vertices are lattice points with coordinates (x, y) satisfying 0 ≤ x ≤ m and 0 ≤ y ≤ n.

For example, Q(2, 2) = 94 as can be seen below:

94 quadrilaterals whose vertices are lattice points with coordinates (x, y) satiffying 0 ≤ x ≤ m and 0 ≤ y ≤ n

It can also be verified that Q(3, 7) = 39\\,590, Q(12, 3) = 309\\,000 and Q(123, 45) = 70\\,542\\,215\\,894\\,646.

Find Q(12\\,345, 6\\,789)\bmod 135\\,707\\,531.

--hints--

latticeQuadrilaterals() should return 104354107.

assert.strictEqual(latticeQuadrilaterals(), 104354107);

--seed--

--seed-contents--

function latticeQuadrilaterals() {

  return true;
}

latticeQuadrilaterals();

--solutions--

// solution required