What are the 3 components of a Bubble sort?
What is the Big O efficiency of a Bubble sort?
O (n^2)
Why are Bubble sort algorithms inefficient?
They require multiple loops through data that has already been sorted
How does a Binary search work?
What is the Big O efficiency of a Binary search?
O (log n)
How does the partition step of a Quicksort work?
How does the recursive step of a Quicksort work?
What swaps would occur if a quicksort was used on this set of numbers? Take 15 as the pivot value
15, 32, 4, 7, 89, 12, 69
What is the Big O efficiency of a Quicksort
0 (n log n)
What is the Big O efficiency of a linear search?
O (n)
How does adding a sentinel value to a linear search increase the efficiency?
Guarantees the search item is found, so eliminates the need to check if the end of the list has been reached.