Skip to content

Add Quick Sort algorithm

Yun.Long requested to merge feature/add-quick-sort into main

Closes #2 (closed) - Add Quick Sort algorithm

Implemented Quick Sort algorithm with the following features:

  • Time complexity: O(n log n) average, O(n²) worst case
  • Space complexity: O(log n)
  • Uses median-of-three pivot selection to avoid worst-case on sorted arrays
  • Follows project conventions for non-mutating sort functions

All 50 tests pass, including:

  • Correctness tests on various input arrays
  • Input mutation verification
  • Algorithm metadata validation
  • Performance test on 1000-element array

Merge request reports