Script Preparation code:
Tests:
Rendered benchmark preparation results:

Suite status: <idle, ready to run>

Previous results
  • Test case name Result
    Array(n).fill(str)
    Array.from({ length: n }, _ => str)
    loop

    Fastest: N/A

    Slowest: N/A

Latest run results:
Run details: (Test run date: one year ago)
Mozilla/5.0 (X11; Linux x86_64; rv:135.0) Gecko/20100101 Firefox/135.0
Firefox 135 on Linux
View result in a separate tab
Array(n).fill(str)
239K/s
loop
98K/s
Array.from({ length: n }, _ => str)
66K/s
View exact numbers
Test name Executions per second
Array(n).fill(str) 238,776 Ops/sec
loop 97,861 Ops/sec
Array.from({ length: n }, _ => str) 66,172 Ops/sec