Home > SparkNotes > Computer Science Study Guides > Bubble >

sparknotes

Bubble Sort


Bubble Sort Problems

Problem : Trace the operation of bubble sort on the following list: 4, 7, 2, 5, 6


Problem : What is the worst case scenario for bubble sort, and why?


Problem : What simple modification could be made to the bubble sort algorithm that would make it perform more efficiently on the case described above?


Problem : What would happen if bubble sort didn't keep track of the number of swaps made on each pass through the list?