feat: Add Heap Sort Algorithm
Closes #{iid} - Add heap sort implementation
Changes
- Implemented heap sort algorithm with O(n log n) time complexity
- Added comprehensive test coverage (automatically included via parametrized tests)
- Updated documentation and demo script
Algorithm Details
- Time Complexity: O(n log n) best/worst case
- Space Complexity: O(1) in-place (O(n) with array copy)
- Stability: Not stable
- Method: Builds max-heap and repeatedly extracts maximum element
Testing
All 50 tests pass, including:
- Correctness tests on 7 different input cases
- Input immutability verification
- Algorithm metadata validation
- Performance benchmarking