forloop

Benchmark created by jsjkskjklsjk on


Setup

var a = [];
    
    for(var i =0; i< 100000;i++){
    a.push(i);
    }

Test runner

Ready to run.

Testing in
TestOps/sec
forIn
for(var key in a){
  console.log(a[key])
}
ready
forLoop
for(var i=0;i < a.length;i++){
  console.log(a[i])
}
ready

Revisions

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

  • Revision 1: published by jsjkskjklsjk on