freeCodeCamp/curriculum/challenges/chinese/08-coding-interview-prep/project-euler/problem-464-mbius-function-...

56 lines
1.4 KiB
Markdown
Raw Normal View History

---
id: 5900f53d1000cf542c51004f
challengeType: 5
title: 'Problem 464: Möbius function and intervals'
videoUrl: ''
localeTitle: 问题464莫比乌斯函数和区间
---
## Description
<section id="description"> Möbius函数表示为μn定义为μn= - 1ωn如果n是无平方其中ωn是n的不同素因子的数量μn 如果n不是无平方则= 0。 <p>令Pab为区间[ab]中的整数n使得μn= 1.设Nab为区间[ab]中的整数n这样μn= -1。例如P2,10= 2且N2,10= 4。 </p><p>令Cn为整数对ab的数目使得1≤a≤b≤n99·Nab≤100·Pab和99·P ab≤100·Nab</p><p>例如C10= 13C500= 16676和C10000= 20155319。 </p><p>找C2 000 000</p></section>
## Instructions
<section id="instructions">
</section>
## Tests
<section id='tests'>
```yml
tests:
- text: <code>euler464()</code>应返回198775297232878。
testString: 'assert.strictEqual(euler464(), 198775297232878, "<code>euler464()</code> should return 198775297232878.");'
```
</section>
## Challenge Seed
<section id='challengeSeed'>
<div id='js-seed'>
```js
function euler464() {
// Good luck!
return true;
}
euler464();
```
</div>
</section>
## Solution
<section id='solution'>
```js
// solution required
```
</section>