black

计算机程序设计综合练习

登录

单项选择题

以下代码片段的输出结果是()
var mingzi = "花花";var cat = {Name:"旺财", prop:{ Name:"小卡", show:function(){ return this.mingzi; } }} console.log(cat.prop.show.call(this));

A.花花
B.旺财
C.小卡
D.报错

相关考题

单项选择题 function foot(){ this.add = function(x,y){ return x+y; }}foot.prototype.add = function(x,y){ return x+y+10;}Object.prototype.substract = function(x,y){ return x-y;}var f1 = new foot();alert(f1.add(1,2));alert(f1.substract(1,2));弹出结果是()

单项选择题 var fun = 1; function fun(a){ console.log(a); } fun(); 以上脚本的运行结果是( )

单项选择题 下列程序的输出是:()var name = globalvar obj = { name: obj, sayName: function () { console.log(this.name); }};obj.sayName();var func = obj.sayName;func();

All Rights Reserved 版权所有©计算机考试题库(PPhuashu.com)

备案号:湘ICP备2020024380号-1