Toggle navigation
MeasureThat.net
Create a benchmark
Tools
Feedback
FAQ
Register
Log In
Find vs some lodash4
(version: 0)
Comparing performance of:
Find vs Some vs Find not vs Some not
Created:
6 years ago
by:
Guest
Jump to the latest result
HTML Preparation code:
<script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/lodash.js/4.17.5/lodash.core.js"></script>
Script Preparation code:
var a = ['hello', 'a', 'bc'];
Tests:
Find
var c = 0; var b = a.indexOf('bc'); if(b >= 0) c++;
Some
var c = 0; var b = _.some(a, item => item === 'bc'); if(b) c++
Find not
var c = 0; var b = a.indexOf('bcc'); if(b < 0) c++;
Some not
var c = 0; var b = _.some(a, item => item === 'bcc'); if(!b) c++
Rendered benchmark preparation results:
Suite status:
<idle, ready to run>
Run tests (4)
Previous results
Fork
Test case name
Result
Find
Some
Find not
Some not
Fastest:
N/A
Slowest:
N/A
Latest run results:
No previous run results
This benchmark does not have any results yet. Be the first one
to run it!
Related benchmarks:
Lodash find vs binary find
native find vs lodash _.find..
Array find vs lodash _.find
native find vs lodash _.find equal
array.find() vs. array.some() - big array version
Comments
Confirm delete:
Do you really want to delete benchmark?