Skip to content
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Commit 4dede0a

Browse files
authoredOct 16, 2017
Added alternative selection sort (cpp)
1 parent a9e3065 commit 4dede0a

File tree

1 file changed

+0
-2
lines changed

1 file changed

+0
-2
lines changed
 

‎Sorting/SelectionSortAlt.cpp

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,8 +23,6 @@ void selection_sort(int *array, std::size_t size, std::function<bool(int, int)>
2323

2424
for (std::size_t next_index = current_index + 1; next_index < size; ++next_index)
2525
{
26-
27-
2826
if (direction(array[preferred_index], array[next_index]))
2927
preferred_index = next_index;
3028
}

0 commit comments

Comments
 (0)
Please sign in to comment.