test (v2)

Revision 2 of this benchmark created on


Setup

const array = [];
for(let index = 0; index < 10000; index++){
	array.push(Math.random())
}
data = array.entries()

Test runner

Ready to run.

Testing in
TestOps/sec
foreach
array.forEach((value,index) => index+value)
ready
for of
for (const value of data) {
  value[0]+value[1]
}
ready

Revisions

You can edit these tests or add more tests to this page by appending /edit to the URL.