Run details:
Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/125.0.0.0 Safari/537.36
Chrome 125
Linux
Desktop
one year ago
Benchmark.js
Array.prototype.forEach.call()
28K/s
Conventional for loop
24K/s
Array.prototype.reduce.call()
23K/s
View exact numbers
| Test name |
Executions per second |
|
✓
Array.prototype.forEach.call()
|
28,386 Ops/sec |
|
Conventional for loop
|
24,056 Ops/sec |
|
Array.prototype.reduce.call()
|
22,805 Ops/sec |
Tests:
-
Array.prototype.reduce.call()
-
Array.prototype.forEach.call()
-
Conventional for loop