Wouldn't `for (var n = 0; n < fromLimit; n++)` work?