Implement a function range(start, end, step) that returns an array of numbers in ascending order.
The function should:
start up to, but not including, end.step to 1 if not provided.start > end.Examples
range(0, 5); // [0, 1, 2, 3, 4] range(2, 10, 2); // [2, 4, 6, 8] range(5, 2, -1); // [5, 4, 3] range(3, 3); // []
JavaScript Function
No test results yet
Click "Run" to execute tests