Run details:
Mozilla/5.0 (Macintosh; Intel Mac OS X 10_11_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/52.0.2743.116 YaBrowser/16.9.0.2765 Safari/537.36
Yandex Browser 16
Mac OS X 10.11.6
Other
8 years ago
Test name Executions per second
spreadArray by ertema 375049.7 Ops/sec
spreadArray by kbakba 313488.2 Ops/sec
spreadArray with comparsion and concat 46998.5 Ops/sec
spreadArray with concat only 43815.3 Ops/sec
spreadArray with comparsion only 461260.8 Ops/sec
spreadArray2 461189.6 Ops/sec
Script Preparation code:
Tests:
  • ComparisonAndConcat

  • Concat

  • Comparison

  • Pop

  • Shift

  • Slice

  • TailSlice

  • Slice2

  • For

  • ForReverse

  • ForComparison

  • ForWithInit

  • ForEach