Toggle navigation
MeasureThat.net
Create a benchmark
Tools
Feedback
FAQ
Register
Log In
Run results for:
Sorting Arrays
This benchmark compares sorting arrays based on spreading and slicing
Go to the benchmark
Embed
Embed Benchmark Result
Run details:
User agent:
Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:120.0) Gecko/20100101 Firefox/120.0
Browser:
Firefox 120
Operating system:
Windows
Device Platform:
Desktop
Date tested:
2 years ago
Test name
Executions per second
With spread
2785.6 Ops/sec
With slice
3208.9 Ops/sec
Tests:
With spread
const array = Array.from(Array(10000).keys()) const sortedArray = [...array].sort()
With slice
const array = Array.from(Array(10000).keys()) const sortedArray = array.slice().sort()