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

873 B
Raw Blame History

id, title, challengeType, videoUrl, dashedName
id title challengeType videoUrl dashedName
5900f3b21000cf542c50fec5 问题70欧拉置换 5 problem-70-totient-permutation

--description--

Euler的Totient函数φn[有时称为phi函数]用于确定小于或等于n的正数的数量它们是n的相对素数。例如如1,2,4,5,7和8都小于9且相对素数为9φ9= 6.数字1被认为是每个正数的相对素数所以φ1= 1。有趣的是φ87109= 79180可以看出87109是79180的置换。找到n的值1 <n <107其中φn是n的置换和比率n / φn产生最小值。

--hints--

euler70()应该返回8319823。

assert.strictEqual(euler70(), 8319823);

--seed--

--seed-contents--

function totientPermutation() {

  return true;
}

totientPermutation();

--solutions--

// solution required