Skip to content

Commit

Permalink
Update src/SortingAlgorithms.jl
Browse files Browse the repository at this point in the history
Co-authored-by: Lilith Orion Hafner <lilithhafner@gmail.com>
  • Loading branch information
nlw0 and LilithHafner authored Sep 4, 2022
1 parent c3b079b commit d464d55
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/SortingAlgorithms.jl
Original file line number Diff line number Diff line change
Expand Up @@ -601,7 +601,7 @@ function sort!(v::AbstractVector, lo::Int, hi::Int, ::CombSortAlg, o::Ordering)
while interval > 1
@inbounds for j in lo:hi-interval
a, b = v[j], v[j+interval]
v[j], v[j+interval] = lt(o, a, b) ? (a, b) : (b, a)
v[j], v[j+interval] = lt(o, b, a) ? (b, a) : (a, b)
end
interval = (3 * interval) >> 2
end
Expand Down

0 comments on commit d464d55

Please sign in to comment.