100k list
uses array includes, array indexOf, and set has
- Array.apply: Array.apply(null, Array(100)) - Destructuring operator: [...Array(100)] - Array.prototype.fill Array(100).fill(undefined) - Array.from Array.from({ length: 100 })
performance comparison of ways to find if an array contains a value
Create Your benchmarks
FAQ: FAQ
Source code: GitHub/MeasureThat.net
Report issues: MeasureThat.net/Issues
Based on: Benchmark.js
Facebook page: https://www.facebook.com/MeasureThat.Net
Python benchmarks support: Pyodide