-
Notifications
You must be signed in to change notification settings - Fork 4
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
lydiahallie/javascript-questions里我的错题 #31
Comments
|
输出结果是什么(() => {
let x = (y = 10);
})();
console.log(typeof x);
console.log(typeof y); 答案
答案:"undefined", "number"
y = 10;
let x = y; 当对 |
输出结果是什么// counter.js
let counter = 10;
export default counter; // index.js
import myCounter from "./counter";
myCounter += 1;
console.log(myCounter); 答案
答案:Error一个被引入的模块是只读的,不能去修改引入的模块。 |
但是,使用 |
输出是什么let num = 10;
const increaseNumber = () => num++;
const increasePassedNumber = number => number++;
const num1 = increaseNumber();
const num2 = increasePassedNumber(num1);
console.log(num1);
console.log(num2); 答案
答案:10, 10
|
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
from https://github.com/lydiahallie/javascript-questions
The text was updated successfully, but these errors were encountered: