Array for vs fill 1e7 (v25)

Revision 25 of this benchmark created on


Test runner

Ready to run.

Testing in
TestOps/sec
Array fill
const A = Array(1e7).fill(0)
ready
Array for
const A = Array(1e7)
for( var i = 0; i < 1e7; i++) {
   A[i] = 0;
}
ready

Revisions

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