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

1016 B

id, title, challengeType, forumTopicId, dashedName
id title challengeType forumTopicId dashedName
5900f50a1000cf542c51001c Problem 413: One-child Numbers 5 302082 problem-413-one-child-numbers

--description--

We say that a d-digit positive number (no leading zeros) is a one-child number if exactly one of its sub-strings is divisible by d.

For example, 5671 is a 4-digit one-child number. Among all its sub-strings 5, 6, 7, 1, 56, 67, 71, 567, 671 and 5671, only 56 is divisible by 4. Similarly, 104 is a 3-digit one-child number because only 0 is divisible by 3. 1132451 is a 7-digit one-child number because only 245 is divisible by 7.

Let F(N) be the number of the one-child numbers less than N. We can verify that F(10) = 9, F(103) = 389 and F(107) = 277674.

Find F(1019).

--hints--

euler413() should return 3079418648040719.

assert.strictEqual(euler413(), 3079418648040719);

--seed--

--seed-contents--

function euler413() {

  return true;
}

euler413();

--solutions--

// solution required