Run details:
Mozilla/5.0 (Macintosh; Intel Mac OS X 10_11) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/104.0.5095.205 Safari/537.36 OPR/83.0.2834.42
Opera 83
Mac OS X 10.11
Desktop
one year ago
Test name Executions per second
for i 5568.2 Ops/sec
for..of 1645.0 Ops/sec
foreach 1950.0 Ops/sec
Script Preparation code:
Tests:
  • for i

  • for..of

  • foreach