Toggle navigation
MeasureThat.net
Create a benchmark
Tools
Feedback
FAQ
Register
Log In
Run results for:
slice vs filter
Go to the benchmark
Embed
Embed Benchmark Result
Run details:
User agent:
Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:124.0) Gecko/20100101 Firefox/124.0
Browser:
Firefox 124
Operating system:
Ubuntu
Device Platform:
Desktop
Date tested:
2 years ago
Test name
Executions per second
slice
754247.4 Ops/sec
filter
1305493.5 Ops/sec
Script Preparation code:
var test=Array.from({length: 100},()=>Math.random())
Tests:
slice
[...test.slice(0,50),...test.slice(51)]
filter
test.filter((e,i)=>i!=50)