Question: Worksheet A17.1 Bubble Sort 1. Practice sorting the following data using Bubble Sort. Write the correct sequence of integers for each value of outer after

 Worksheet A17.1 Bubble Sort 1. Practice sorting the following data usingBubble Sort. Write the correct sequence of integers for each value ofouter after its inner loop has been completed: outer 84 50 6282 83 15 0 1 2 3 4 2. Practice sorting wordsusing Bubble Sort. Write the correct sequence of words for each valueof outer after its inner loop has been completed: outer eat steaks

Worksheet A17.1 Bubble Sort 1. Practice sorting the following data using Bubble Sort. Write the correct sequence of integers for each value of outer after its inner loop has been completed: outer 84 50 62 82 83 15 0 1 2 3 4 2. Practice sorting words using Bubble Sort. Write the correct sequence of words for each value of outer after its inner loop has been completed: outer eat steaks juicy huge dogs big 0 1 2 3 4 public void bubbleSort (ArrayList list) { for (int outer = 0; outer list.get(inner + 1)) { // swap list[inner] & list (inner+1] int temp = list.get(inner); list.set (inner, list.get (inner + 1)); list. set (inner + 1, temp); } } } Worksheet A17.2 Selection Sort 1. Practice sorting the following data using Selection Sort. Write the correct sequence of integers for each value of outer after its inner loop has been completed: outer 20 2 10 34 83 29 0 1 2 3 4 2. Practice sorting words using Selection Sort. Write the correct sequence of words for each value of outer after its inner loop and swap have been completed: outer programs java always very well document 0 1 2 3 public void selectionsort (ArrayList list) { int min, temp; for (int outer = 0; outer list) for (int outer - 17 Duter 0 list.get(position - 1) > key) list.set(position, list.get(position - 1)); position--; } list.set(position, key); )

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!