Run details:
Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/106.0.0.0 Safari/537.36
Chrome 106
Mac OS X 10.15.7
Desktop
2 years ago
Test name Executions per second
for..in 99880.9 Ops/sec
foreach 9046096.0 Ops/sec
some 7408974.0 Ops/sec
for 82209.1 Ops/sec
for with predefined size 159648.9 Ops/sec
while 3102904.8 Ops/sec
Script Preparation code:
Tests:
  • for..in

  • foreach

  • some

  • for

  • for with predefined size

  • while