Benchmarks

Windows Benchmark: Linear Search (x5)

Linear Search is a search algorithm that finds the position of a target value within any kind of array. Performs a linear search through 50 integers in an array for the 4th, 11th, 29th, 36th, and 42nd elements.

number search

All-Time Rankings

Rank Language Average Time Best Time Worst Time
1 Go 0.000µs 0.000µs 0.000µs
2 C (GCC) 0.292µs 0.200µs 0.400µs
3 C++ (G++) 0.308µs 0.200µs 0.400µs
4 D 0.460µs 0.400µs 0.500µs
5 C (Clang) 0.476µs 0.400µs 0.800µs
6 C++ (Clang++) 0.560µs 0.500µs 0.800µs
7 Kotlin (Native) 1.660µs 1.500µs 1.900µs
8 Zig 3.920µs 3.300µs 5.400µs
9 Rust 5.464µs 4.800µs 6.400µs
10 Java 6.268µs 5.700µs 7.100µs
11 Python 13.204µs 12.000µs 14.800µs
12 PHP 17.192µs 13.000µs 69.700µs
13 GraalVM 23.652µs 3.200µs 495.600µs
14 Ruby 31.648µs 27.900µs 54.400µs
15 JavaScript (Node) 58.016µs 50.500µs 71.900µs
16 JavaScript (Deno) 58.168µs 49.600µs 77.500µs
17 JavaScript (Bun) 92.952µs 42.700µs 950.100µs
18 Kotlin (JVM) 7,313.556µs 2,187.400µs 49,624.101µs

Average Times

Median Times

Best-Case Scenario Times

Worst-Case Scenario Times