topic description
about object assignment
sources of topics and their own ideas
Source interview questions
related codes
/ / Please paste the code text below (do not replace the code with pictures)
var o={};
o.a=0;
var b=o;
b.a=10;
console.log(a);//a=0
what result do you expect? What is the error message actually seen?
an is an attribute of object o, so why can console.log (a) output 0? He is not a variable under window