Toggle navigation
MeasureThat.net
Create a benchmark
Tools
Feedback
FAQ
Register
Log In
Run results for:
1134112
Go to the benchmark
Embed
Embed Benchmark Result
Run details:
User agent:
Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:127.0) Gecko/20100101 Firefox/127.0
Browser:
Firefox 127
Operating system:
Mac OS X 10.15
Device Platform:
Desktop
Date tested:
one year ago
Test name
Executions per second
1
8813060.0 Ops/sec
2
36502480.0 Ops/sec
Tests:
1
const max = 5; const arr = [1, 0, () => {}, '', {}]; const fArr = Array.from({ length: max }, (_, i) => arr[i]); const nArr = fArr.filter(Boolean);
2
const max = 5; const arr = [1, 0, () => {}, '', {}]; const fArr = []; const nArr = []; for (let i = 0; i < max; i += 1) { const el = arr[i]; fArr.push(el); if (el) nArr.push(el); }