e-commercee
Version:
This package contains a backend of what would be the logic of a e-commercee software, the architecture used is made in 3 layers
22 lines (18 loc) • 344 B
JavaScript
;
/**
* Create an array of numbers.
* @param {number} from
* @param {number} to
* @returns {number[]}
*/
function range(from, to) {
// TODO: make this inlined.
const list = new Array(to - from + 1);
for (let i = 0; i < list.length; i += 1) {
list[i] = from + i;
}
return list;
}
module.exports = {
range,
};