HTML Preparation code:
AخA
 
1
<script src="https://cdn.jsdelivr.net/npm/lodash@4.17.5/lodash.min.js"></script>
Script Preparation code:
x
 
var firstEqual = [];
var secondEqual = [];
for (var i=0; i<=100; i++) {
  firstEqual.push(i);
  secondEqual.push(i);
}
var arrayToDedup = [...firstEqual, ...secondEqual];
Tests:
  • tets1

     
    _.uniq(arrayToDedup);
  • test2

     
    [...new Set(arrayToDedup)]
Rendered benchmark preparation results:

Suite status: <idle, ready to run>

Previous results

Experimental features:

  • Test case name Result
    tets1
    test2

    Fastest: N/A

    Slowest: N/A

Latest run results:
Run details: (Test run date: 5 years ago)
Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_1) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/78.0.3904.108 Safari/537.36
Chrome 78 on Mac OS X 10.15.1
View result in a separate tab
Test name Executions per second
tets1 166385.8 Ops/sec
test2 204625.0 Ops/sec