--- id: cf1111c1c11feddfaeb6bdef title: Divide One Number by Another with JavaScript challengeType: 1 videoUrl: '' localeTitle: 用JavaScript划分一个号码 --- ## Description 我们也可以将一个数字除以另一个数字。 JavaScript使用/符号进行除法。 例 myVar = 16/2; //分配8 ## Instructions 更改0 ,使quotient等于2 。 ## Tests ```yml tests: - text: 使变量quotient等于2。 testString: assert(quotient === 2); - text: 使用/运算符 testString: assert(/\d+\s*\/\s*\d+/.test(code)); ``` ## Challenge Seed ```js var quotient = 66 / 0; ``` ### After Test ```js console.info('after the test'); ``` ## Solution ```js // solution required ```
/
例
myVar = 16/2; //分配8
0
quotient
2