* 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>
1.4 KiB
1.4 KiB
id, title, challengeType, videoUrl, dashedName
id | title | challengeType | videoUrl | dashedName |
---|---|---|---|---|
5900f4be1000cf542c50ffd1 | 问题338:切割矩形网格纸 | 5 | problem-338-cutting-rectangular-grid-paper |
--description--
给出了具有整数尺寸w×h的矩形网格纸。它的网格间距为1.当我们沿着网格线将纸张切割成两个部分并重新排列这些部分而没有重叠时,我们可以制作具有不同尺寸的新矩形。例如,从尺寸为9×4的纸张中,我们可以通过切割和重新排列来制作尺寸为18×2,12×3和6×6的矩形,如下所示:
同样,从尺寸为9×8的纸张中,我们可以制作尺寸为18×4和12×6的矩形。
对于w和h对,让F(w,h)是可以由尺寸为w×h的薄片制成的不同矩形的数量。例如,F(2,1)= 0,F(2,2)= 1,F(9,4)= 3和F(9,8)= 2.注意,与初始一致的矩形不计算在内在F(w,h)。还要注意,尺寸为w×h且尺寸为h×w的矩形不被认为是不同的。
对于整数N,令G(N)为满足0 <h≤w≤N的所有w和h的F(w,h)之和。我们可以验证G(10)= 55,G(103) )= 971745和G(105)= 9992617687。
找到G(1012)。给你的答案模数108。
--hints--
euler338()
应该返回15614292。
assert.strictEqual(euler338(), 15614292);
--seed--
--seed-contents--
function euler338() {
return true;
}
euler338();
--solutions--
// solution required