Chapter 1 - Algorithms

Cards (4)

  • Bubble Sort - Compare adjacent items in a list, if in order leave them, if they are not in order, swap them. Completed when there is a pass with no swaps
  • Quick Sort - Select the middle number as a pivot, work from left to right putting numbers above or below the pivot so they are getting closer to the correct order. Completed when all numbers have been pivots
  • Order of an Algorithm (we know f(n)f(n)) = x seconds times f(m)/f(n)f(m)/f(n)
  • Lower Bound for Bin Packing = Sum of Numbers / Bin Size