nit: cache Date.now before the loop?