Toggle navigation
MeasureThat
.net
Create a benchmark
Tools
Feedback
FAQ
Register
Log In
Run results for:
splice vs double pop
100k list
Go to the benchmark
Embed
Embed Benchmark Result
Run details:
User agent:
Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/145.0.0.0 Safari/537.36
Browser:
Chrome 145
Operating system:
Linux
Device Platform:
Desktop
Date tested:
5 months ago
double pop
61.1M/s
splice
4.0M/s
View exact numbers
Test name
Executions per second
✓
double pop
61,121,576 Ops/sec
splice
3,984,402 Ops/sec
Script Preparation code:
var list = []; for (var i = 0; i < 1000 * 1000; i++) { list.push(i); }
Tests:
splice
list = list.splice(list.length-2,2)
double pop
list.pop() list.pop()