Toggle navigation
MeasureThat.net
Create a benchmark
Tools
Feedback
FAQ
Register
Log In
Run results for:
includes-mapping-set
Go to the benchmark
Embed
Embed Benchmark Result
Run details:
User agent:
Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/136.0.0.0 Safari/537.36
Browser:
Chrome 136
Operating system:
Mac OS X 10.15.7
Device Platform:
Desktop
Date tested:
one year ago
Test name
Executions per second
includes
3.1 Ops/sec
mappiing
436.5 Ops/sec
set
84.2 Ops/sec
HTML Preparation code:
<!--your preparation HTML code goes here-->
Script Preparation code:
/*your preparation JavaScript code goes here To execute async code during the script preparation, wrap it as function globalMeasureThatScriptPrepareFunction, example:*/ const arr = [] for(let i =0;i<300000;i++){ arr.push(i) }
Tests:
includes
for(let i=0;i<10000;i++){ arr.includes(300000) }
mappiing
const map = {} const arrLen = arr.length for(let i=0;i<arrLen;i++){ map[arr[i]] = true } for(let i=0;i<10000;i++){ map[300000] }
set
const set = new Set(arr) for(let i=0;i<10000;i++){ set.has(300000) }