Response title
This is preview!
i get totally confused this alert call one time how ?
var i = 0;
function call(name) {
if (i === 0) {
setTimeout(function () {
alert(name);
i = 0
}, 1000);
} i++;
}
call('as');
call('as1');
call('as');
call('as1')
var i = 0, obj=[];
function call(name) {
obj[i]=name;
if (i === 0) {
setTimeout(function () {
alert(obj);
i = 0
}, 0);
} i++;
}
call('as');
call('as1');
call('as');
call('as1')
© 2013 jQuery Foundation
Sponsored by and others.