最贊回答 / winner_DOIT
首先清楚countMap1 和?countMap2是對象,其次清楚countMap1[t1]作用是給countMap1對象設置屬性,然后countMap1[t1]++ 和countMap1[t1] = 1都是給countMap1的t1屬性賦值,TYPES[i] 這個意思是獲取數組里第i個位置的值,例如:TYPES[0] 的值為‘string’,最后?if(countMap1[TYPES[i]].length !== countMap2[TYPES[i]].length){ ? return false;}...
2017-05-22
最新回答 / 灰色信念
<iframe width="214" scrolling="no" height="54" frameborder="0" allowtransparency="true" src="http://i.tianqi.com/index.php?c=code&id=42&icon=1&num=3"></iframe>調用天氣預報插件
2017-05-15
最新回答 / 寶慕林1151284
首先Student.prototype 不會指向 Person.prototype;而是Student.prototype._proto_指向Person.prototype。也不存在直接指向 Person;他們之間的繼承是通過原型鏈,一一往上繼承使用的。這不是嚴格像Java那樣繼承,感覺是這樣繼承的形式,本質上還是有區別的。
2017-05-12
最贊回答 / 禾木89
寫一下我的理解toString()方法是沒有參數的.相當于var o ={? ? toString? :? function(){? ? ? ? ? ? ?console.log("無論你傳給我什么我都輸出這行字.")? ? }};你用到函數toString()的時候,只能o.toString()無論是o.toString('99999'),還是o.toString('88888'),對函數輸出的結果 沒有影響所以Object.prototype.toString(this) ,?這樣寫的話對輸出結果是沒...
2017-04-26