Toggle navigation
MeasureThat.net
Create a benchmark
Tools
Feedback
FAQ
Register
Log In
some vs for...break
(version: 1)
Comparing performance of:
some vs for..break
Created:
one year ago
by:
Guest
Jump to the latest result
HTML Preparation code:
<!--your preparation HTML code goes here-->
Script Preparation code:
var data = [] for (let i = 0; i < 5000; ++i) data.push({ username: 'toto' }) data.push({ username: 'titi' }) for (let i = 0; i < 2500; ++i) data.push({ username: 'toto' })
Tests:
some
data.some(item => item.username === 'titi');
for..break
for (const item of data) { if (item.username === 'titi') return true; } return false;
Rendered benchmark preparation results:
Suite status:
<idle, ready to run>
Run tests (2)
Previous results
Fork
Test case name
Result
some
for..break
Fastest:
N/A
Slowest:
N/A
Latest run results:
Run details:
(Test run date:
one year ago
)
User agent:
Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/131.0.0.0 Safari/537.36
Browser/OS:
Chrome 131 on Windows
View result in a separate tab
Embed
Embed Benchmark Result
Test name
Executions per second
some
265820.2 Ops/sec
for..break
259827.9 Ops/sec
Related benchmarks:
Some vs !!Find
Some vs Includes wtf
Some vs Find vs For
test find vs some
Some vs Find vs Loop
Some vs Find for non existence check
Some vs Find atata
Some vs Find v1
Some vs Find bool
Comments
Confirm delete:
Do you really want to delete benchmark?