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.
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
src/<category>/<algorithm>.rs.#[cfg(test)] mod tests { ... }covering empty, single-element, and representative inputs.slice::sort).cargo fmt --check,cargo clippy --all-targets -- -D warnings, andcargo testall pass.