Skip to content

Commit 2f1645e

Browse files
replace Collections.swap() with 'also'
1 parent 72c20ba commit 2f1645e

File tree

1 file changed

+0
-2
lines changed

1 file changed

+0
-2
lines changed

src/main/kotlin/codecollection/algorithms/SelectionSort.kt

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,5 @@
11
package codecollection.algorithms
22

3-
import java.util.Collections
4-
53
fun selectionSort(list: List<Int>): List<Int> {
64
if (list.size <= 1) return list
75
val result = list.toMutableList()

0 commit comments

Comments
 (0)