Run details:
Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/102.0.5005.63 Safari/537.36 Edg/102.0.1245.33
Chrome 102
Windows
Desktop
2 years ago
Test name Executions per second
for 27088.1 Ops/sec
foreach 1659250.0 Ops/sec
some 1712919.4 Ops/sec
every 1738945.5 Ops/sec
for..of 53254.4 Ops/sec
map 1712125.4 Ops/sec
Script Preparation code:
Tests:
  • for

  • foreach

  • some

  • every

  • for..of

  • map