Benchmark: sqrt(x) (100K)
Benchmark the performance of the sqrt
function, between 1 and 100,000.
number
math
100K
All-Time Rankings
Rank | Language | Average Time | Best Time | Worst Time |
---|---|---|---|---|
1 | Go | 190.360µs | 169.000µs | 313.000µs |
2 | Kotlin (Native) | 261.291µs | 217.016µs | 615.958µs |
3 | C++ (Clang++) | 603.985µs | 565.462µs | 878.316µs |
4 | C (Clang) | 614.183µs | 565.429µs | 996.051µs |
5 | C (GCC) | 757.753µs | 676.932µs | 978.746µs |
6 | Rust | 874.040µs | 800.000µs | 1,092.000µs |
7 | C++ (G++) | 950.920µs | 894.000µs | 1,191.000µs |
8 | Kotlin (JVM) | 20,908.252µs | 2,807.400µs | 420,445.985µs |
9 | PHP | 25,720.551µs | 6,127.968µs | 459,334.140µs |
10 | JavaScript (Bun) | 31,800.967µs | 2,545.883µs | 635,677.526µs |
11 | Java | 94,201.996µs | 2,500.752µs | 1,041,471.551µs |
12 | Ruby | 100,149.080µs | 10,600.000µs | 1,253,103.000µs |
13 | Python | 112,687.600µs | 16,138.000µs | 899,344.000µs |
14 | JavaScript (Deno) | 125,203.933µs | 2,672.429µs | 1,016,782.385µs |
15 | JavaScript (Node) | 204,080.224µs | 1,997.219µs | 1,144,757.806µs |