??????????к????????
?????????????????????к??????????
????var immediate_one = function() {
????return 1;
????}();
????console.log(immediate_one) ; //1
????????????????????????????????????????в??????????????????immediate_one
?????????????????????£?
????var immediate_one = function() {
????return 1;
????}
???????immediate????????????????????????????????????????????????У????????????????????????????????
???????????μ?д??????????
????function myfunc() {
????return 1;
????}();
??????????Firefox?????????????μ????

???????????myfunc????ú??????????????????????????????????????????????????????????????????????????????λ??δ?????????ú?????????????????????????????????????????????????????????
????(function myfunc() {
????return 1;
????})();
????????????????????????????????????棬???к??????????????????У???????????λ????????????У????????????????????????????????????????????????ú?????????????????????????????????????棨???????ú????????????????????????????????????????????????????????????????????????????????????????????????????÷??????????????????Ч???
????(function myfunc() {
????return 1;
????}())
??????????к?????????
????a.?????????
??????????к?????????÷??????????????????????????????????Щ????????????????????????????????????????????????????????????????????????????е????????????к??????棬??ú??????????????????
???????′??????????????????????????????????????????
????(function() {
????for(var i = 1; i <= 3; i++) {
????document.getElementById("button-" + i).onclick = function() {
????//???????????????д??????
????}
????}
????}());
?????????????????к?????????i????????????????????棬???????????
????b.????????
??????????к?????????????????????????????????????????????????У?????????????????????????
????????????????????????????
????var next?? previous?? rewind;
????(function(){
????var index = -1??
????data = ["eeny"?? "meeny"?? "miny"?? "moe"]??
????count = data.length;
????next = function() {
????if(index < count) {
????index++;
????}
????return data[index];
????}
????previous = function() {
????if(index >= 0) {
????index--;
????}
????return data[index];
????}
????rewind = function() {
????index = -1;
????}
????}());
????console.log(next()); //eeny
????console.log(previous()); //undefined
????console.log(next()); //eeny
????console.log(next()); //meeny
????????????У?inde??data??count????е?? ???????????????????????????????????????????????????????????????????????????????????????