search and replace ```\n< with ```\n\n< to ensure there's an empty line before closing tags
1.6 KiB
1.6 KiB
id, title, challengeType, videoUrl, localeTitle
id | title | challengeType | videoUrl | localeTitle |
---|---|---|---|---|
587d7b85367417b2b2512b39 | Catch Missing Open and Closing Parenthesis After a Function Call | 1 | 在函数调用后捕获缺失的打开和关闭括号 |
Description
function myFunction(){
回归“你摇滚!”;
}
let varOne = myFunction; //设置为等于函数
let varTwo = myFunction(); //设置为等于字符串“You rock!”
Instructions
result
设置为调用函数getNine
返回的值。 Tests
tests:
- text: 您的代码应修复变量<code>result</code>以便将其设置为函数<code>getNine</code>返回的数字。
testString: assert(result == 9);
- text: 您的代码应该调用<code>getNine</code>函数。
testString: assert(code.match(/getNine\(\)/g).length == 2);
Challenge Seed
function getNine() {
let x = 6;
let y = 3;
return x + y;
}
let result = getNine;
console.log(result);
Solution
// solution required
/section>