倒计时 var total = 3600; var t = setInterval(function(){ total--; if(total == 0){ clearInterval(t); return; } console.log( formatNumber(parseInt(total/60)) , formatNumber(total%60) ); }, 100);