logo Practice-It logo

selectionSort

Language/Type: Java selection sort sorting
Author: Eric Spishak

Write the state of the elements of the array below after each of the first 3 passes of the outermost loop of the selection sort algorithm.

int[] numbers = {45, 78, 89, 34, 23, 12, 67, 56};
selectionSort(numbers);
after pass 1
after pass 2
after pass 3

You must log in before you can solve this problem.


Log In

If you do not understand how to solve a problem or why your solution doesn't work, please contact your TA or instructor.
If something seems wrong with the site (errors, slow performance, incorrect problems/tests, etc.), please

Is there a problem? Contact a site administrator.