chore(learn): Applied MDX format to Chinese curriculum files (#40462)
This commit is contained in:
@ -1,55 +1,27 @@
|
||||
---
|
||||
id: 59713bd26bdeb8a594fb9413
|
||||
title: 计算硬币
|
||||
challengeType: 5
|
||||
videoUrl: ''
|
||||
title: 计算硬币
|
||||
---
|
||||
|
||||
## Description
|
||||
<section id="description"><p> <a href="https://en.wikipedia.org/wiki/United_States" title="链接:https://en.wikipedia.org/wiki/United_States">美国</a>货币有四种常见硬币: </p>季度(25美分)硬币(10美分)镍(5美分)和便士(1美分) <p>有六种方法可以换15美分: </p>一角钱和一角钱一角钱和5便士3镍2镍和5便士一镍和10便士15便士任务: <p>实现一个功能,以确定使用这些普通硬币改变一美元的方式有多少? (1美元= 100美分)。 </p>参考: <a href="http://mitpress.mit.edu/sicp/full-text/book/book-Z-H-11.html#%_sec_Temp_52" title="链接:http://mitpress.mit.edu/sicp/full-text/book/book-Z-H-11.html#%_sec_Temp_52">麻省理工学院出版社的算法</a> 。 </section>
|
||||
# --description--
|
||||
|
||||
## Instructions
|
||||
<section id="instructions">
|
||||
</section>
|
||||
<p> <a href='https://en.wikipedia.org/wiki/United_States' title='链接:https://en.wikipedia.org/wiki/United_States'>美国</a>货币有四种常见硬币: </p>季度(25美分)硬币(10美分)镍(5美分)和便士(1美分) <p>有六种方法可以换15美分: </p>一角钱和一角钱一角钱和5便士3镍2镍和5便士一镍和10便士15便士任务: <p>实现一个功能,以确定使用这些普通硬币改变一美元的方式有多少? (1美元= 100美分)。 </p>参考: <a href='http://mitpress.mit.edu/sicp/full-text/book/book-Z-H-11.html#%_sec_Temp_52' title='链接:http://mitpress.mit.edu/sicp/full-text/book/book-Z-H-11.html#%_sec_Temp_52'>麻省理工学院出版社的算法</a> 。
|
||||
|
||||
## Tests
|
||||
<section id='tests'>
|
||||
# --hints--
|
||||
|
||||
```yml
|
||||
tests:
|
||||
- text: <code>countCoins</code>是一个函数。
|
||||
testString: assert(typeof countCoins === 'function');
|
||||
- text: <code>countCoints()</code>应该返回242。
|
||||
testString: assert.equal(countCoins(), 242);
|
||||
|
||||
```
|
||||
|
||||
</section>
|
||||
|
||||
## Challenge Seed
|
||||
<section id='challengeSeed'>
|
||||
|
||||
<div id='js-seed'>
|
||||
`countCoins`是一个函数。
|
||||
|
||||
```js
|
||||
function countCoins () {
|
||||
// Good luck!
|
||||
return true;
|
||||
}
|
||||
|
||||
assert(typeof countCoins === 'function');
|
||||
```
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
</section>
|
||||
|
||||
## Solution
|
||||
<section id='solution'>
|
||||
`countCoints()`应该返回242。
|
||||
|
||||
```js
|
||||
// solution required
|
||||
assert.equal(countCoins(), 242);
|
||||
```
|
||||
|
||||
/section>
|
||||
# --solutions--
|
||||
|
||||
|
Reference in New Issue
Block a user