re: How to create range in Javascript VIEW POST

TOP OF THREAD FULL DISCUSSION
re: I just use a one-liner recursive arrow function in ES6; note, it doesn't check but you should only pass it integers else it will never get to a == ...
 
Sloan, the sloth mascot Comment marked as low quality/non-constructive by the community View code of conduct

Are you actually using this in production code? 😂😂

You realise how inefficient this is right? 😂😂

 

I have adapted Namir's method (see comments). And it is probably the most efficient.

code of conduct - report abuse