freeCodeCamp/curriculum/challenges/chinese/10-coding-interview-prep/project-euler/problem-374-maximum-integer-partition-product.md
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.2 KiB
Raw Blame History

id, title, challengeType, videoUrl, dashedName
id title challengeType videoUrl dashedName
5900f4e51000cf542c50fff6 问题374最大整数分区产品 5 problem-374-maximum-integer-partition-product

--description--

数字n的整数分区是将n写为正整数之和的方法。

仅按其加数顺序不同的分区被认为是相同的。将n分成不同部分是n的分区其中每个部分最多出现一次。

5个不同部分的分区是5,4 + 1和3 + 2。

设fn是n的任何这种分区的部分到不同部分的最大乘积并且令mn是具有该乘积的n的任何这种分区的元素的数量。

所以f5= 6m5= 2。

对于n = 10具有最大乘积的分区是10 = 2 + 3 + 5其给出f10= 30和m10= 3。并且他们的产品f10·m10= 30·3 = 90

可以证实Σfn·mn对于1≤n≤100= 1683550844462。

找到Σfn·mn为1≤n≤1014。给出你的答案模数982451653即第5000万个素数。

--hints--

euler374()应该返回334420941。

assert.strictEqual(euler374(), 334420941);

--seed--

--seed-contents--

function euler374() {

  return true;
}

euler374();

--solutions--

// solution required