Toggle navigation
MeasureThat.net
Create a benchmark
Tools
Feedback
FAQ
Register
Log In
arr unshift vs push + reverse (small array) 2
(version: 1)
Comparing performance of:
unshift vs push + reverse
Created:
one year ago
by:
Guest
Jump to the latest result
Script Preparation code:
var arr = [100];
Tests:
unshift
for (let i = 0; i < 100; i++){ arr.unshift(i); }
push + reverse
for (let i = 0; i < 100; i++){ arr.push(i); } arr.reverse();
Rendered benchmark preparation results:
Suite status:
<idle, ready to run>
Run tests (2)
Previous results
Fork
Test case name
Result
unshift
push + reverse
Fastest:
N/A
Slowest:
N/A
Latest run results:
No previous run results
This benchmark does not have any results yet. Be the first one
to run it!
Comments
Confirm delete:
Do you really want to delete benchmark?