1 2 3 4 5 6 7 8 9 | function xrange(b0, b1, quantum) {
if (!quantum) { quantum = 1; }
if (!b1) { b1 = b0; b0 = 0; }
out = [];
for (var i = b0, idx = 0; i < b1; i += quantum, idx++) {
out[idx] = i;
}
return out;
}
|
More like this
- Use git log to give your app a revision by peterbe 3 years, 6 months ago
- Python-like string interpolation in Javascript by phxx 2 years, 11 months ago
- Dynamical formsets by I159 1 year, 6 months ago
- Export Django data to datestamped tarball -- choose individual models for handy packaging and archiving by fish2000 2 years, 8 months ago
- Client-side Django-style date & time string formatting by robbie 6 years, 2 months ago
Comments