function Test() { }
var test = new Test();
Test.prototype.member='World';
var test2 = new Test();
var a = test.member; // 1
var b = test2.member; // 2
Which of the following statements are true?
Could you give an explanation why 'a' also contains 'World'? Do added properties in prototype hoist?
2018 Jun 19, 1:58:55 PM
Войдите чтобы поставить Нравится
Войдите чтобы прокомментировать