with reduce() vs with sort()Fastest: with reduce() (2.6x faster)
1 ops/sec
0 ops/sec
Results show median performance across all community submissions. Run this benchmark yourself to verify on your device.
| Test case name | Result |
|---|---|
| with reduce() | |
| with sort() |
| Test name | Executions per second |
|---|---|
| ✓ with sort() | 1 Ops/sec |
| with reduce() | 1 Ops/sec |