Skip to content

Add comb sort #3

Description

@0xDevNinja

A bubble-sort variant using a shrinking gap (Knuth shrink factor 1.3). Improves bubble sort to roughly O(n log n) in practice.

Acceptance criteria

  • Implementation lives in src/<category>/<algorithm>.rs.
  • Inline #[cfg(test)] mod tests { ... } covering empty, single-element, and representative inputs.
  • Property test (where feasible) comparing against a reference implementation (e.g. slice::sort).
  • Doc comment on the public function names the algorithm and its complexity.
  • cargo fmt --check, cargo clippy --all-targets -- -D warnings, and cargo test all pass.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions