Skip to content
loading...

re: #7DaysJS: Even or Odd VIEW POST

FULL DISCUSSION
 

I used a filter for even and odd, then a reduce for both. Probably cost the browser more power eh?

 

Probably. Usually, for loops are faster, but maybe with larger inputs reduce outworks a for loop...

code of conduct - report abuse