Run details:
Mozilla/5.0 (Macintosh; Intel Mac OS X 10.13; rv:58.0) Gecko/20100101 Firefox/58.0
Firefox 58
Mac OS X 10.13
Other
2025 years ago
Test name Executions per second
for..in 169557.3 Ops/sec
foreach 18224426.0 Ops/sec
some 116637096.0 Ops/sec
for 1640953.9 Ops/sec
for with predefined size 2984254.0 Ops/sec
while 23149942.0 Ops/sec
Script Preparation code:
Tests:
  • for..in

  • foreach

  • some

  • for

  • for with predefined size

  • while