about | help | code help+videos | done | prefs |
selectionSort
Implement the selection sort algorithm using recursion. <p> Normally, sorting algorithms should have return type void. But codingbat doesn't work that way. So, return the array at the end of the method. selectionSort([47, 2, 18, 6, 3, 59, 2, 8, 19, 5]) → [2, 2, 3, 5, 6, 8, 18, 19, 47, 59] selectionSort([4, 3, 2, 1]) → [1, 2, 3, 4] selectionSort([5]) → [5] ...Save, Compile, Run (ctrl-enter) |
Progress graphs:
Your progress graph for this problem
Random user progress graph for this problem
Random Epic Progress Graph
Difficulty: 200
Copyright Nick Parlante 2017 - privacy