answersLogoWhite

0


Best Answer

Passes:

bold are "sunk" into place

1: 5 19 2 7 28

2: 5 2 7 19 28

3: 2 5 7 19 28

4*: 2 5 7 19 28

*The last pass had no swaps, thus it breaks out of the sort

Efficiency: O(n^2) in random order O(n) when already sorted

User Avatar

Wiki User

16y ago
This answer is:
User Avatar

Add your answer:

Earn +20 pts
Q: Sort the following numbers 19 5 28 2 7 using bubble sort?
Write your answer...
Submit
Still have questions?
magnify glass
imp
Related questions

How do write sorting of numbers using microprocessor?

There are several methods available to sort numbers. A simple way to program sorting is the so-called "bubble-sort". This is inefficient for larger lists of numbers; in which case it is more convenient to use one of the faster algorithms, for example, "quick-sort".


How can you put in order a list of telephone numbers?

You could use a bubble sort.


How many key comparison and interchanges are required to sort a file of size n using bubble sort?

rfsghdfhdh


What Program that lists telephone numbers in numeric order or street address?

In programming this could be achieved using a numeric bubble sort. Excel allows this type of sorting to be used.


What is another name for bubble sort?

Bubble sort is also known as sinking sort.


Divide-and-Conquer to sort numbers using quick sort?

Yes, that's how quick-sort works.


Who invented the bubble sort?

ramesh


Bubble sort Extra or in space?

Bubble sort is an "in place" algorithm. Other than a temporary "switch" variable, no extra space is required.


Ignou mca solved assignment of 3rd sem Jan 2009 free?

Sort the following list of numbers in the descending order, 187, 62, 155, 343, 184, 958, 365, 427, 78, 94, 121, 388 using each of the following methods: (i) Insertion Sort (ii) Selection Sort (iii) Heap Sort (iv) Merge Sort (v) Quick Sort Further, count the number of operations, by each sorting method.


What is bubble sort and explain with examples?

bubbles


Can you draw a flow chart for bubble sort?

no


What are some sorting rules for math?

Binary sort and bubble sort are two.