Oliver Eyton-Williams ee1e8abd87
feat(curriculum): restore seed + solution to Chinese (#40683)
* feat(tools): add seed/solution restore script

* chore(curriculum): remove empty sections' markers

* chore(curriculum): add seed + solution to Chinese

* chore: remove old formatter

* fix: update getChallenges

parse translated challenges separately, without reference to the source

* chore(curriculum): add dashedName to English

* chore(curriculum): add dashedName to Chinese

* refactor: remove unused challenge property 'name'

* fix: relax dashedName requirement

* fix: stray tag

Remove stray `pre` tag from challenge file.

Signed-off-by: nhcarrigan <nhcarrigan@gmail.com>

Co-authored-by: nhcarrigan <nhcarrigan@gmail.com>
2021-01-12 19:31:00 -07:00

1.8 KiB

id, title, challengeType, forumTopicId, dashedName
id title challengeType forumTopicId dashedName
5900f5191000cf542c51002b Problem 428: Necklace of Circles 5 302098 problem-428-necklace-of-circles

--description--

Let a, b and c be positive numbers.

Let W, X, Y, Z be four collinear points where |WX| = a, |XY| = b, |YZ| = c and |WZ| = a + b + c.

Let Cin be the circle having the diameter XY.

Let Cout be the circle having the diameter WZ.

The triplet (a, b, c) is called a necklace triplet if you can place k ≥ 3 distinct circles C1, C2, ..., Ck such that:

  • Ci has no common interior points with any Cj for 1 ≤ i, jk and ij,
  • Ci is tangent to both Cin and Cout for 1 ≤ ik,
  • Ci is tangent to Ci+1 for 1 ≤ i < k, and
  • Ck is tangent to C1.
For example, (5, 5, 5) and (4, 3, 21) are necklace triplets, while it can be shown that (2, 2, 5) is not. a visual representation of a necklace triplet

Let T(n) be the number of necklace triplets (a, b, c) such that a, b and c are positive integers, and bn. For example, T(1) = 9, T(20) = 732 and T(3000) = 438106.

Find T(1 000 000 000).

--hints--

necklace(1000000000) should return 747215561862.

assert.strictEqual(necklace(1000000000), 747215561862);

--seed--

--seed-contents--

function necklace(n) {

  return true;
}

necklace(1000000000)

--solutions--

// solution required