以下代码的运行结果将会是?var foot = {kick: function () {this.yelp = "Ouch!";setImmediate(function () {console.log(this.yelp);});}};foot.kick();
A. Ouch!
B. null
C. undefined
D. Uncaught TypeError
以下代码的输出结果是:let numbers = [1, 2, 3];let data = {};[data.foo, data.bar] = numbers;console.log(data);
A. 1,2
B. 1,3
C. { foo: 1, bar: 2 }
D. { foo: 1, bar: 3 }
在下列代码中,那段代码可以求算出numbers数组的最大值?
A. var numbers = [1, 1, 2, 3, 5, 8];var max = Math.max(numbers);
B. var numbers = [1, 1, 2, 3, 5, 8];var max = Math.max(...numbers);
C. var numbers = [1, 1, 2, 3, 5, 8];var max = Math.max(numbers...);
D. var numbers = [1, 1, 2, 3, 5, 8];var max = Math.max(*numbers);