Outline for May 22, 2009

Reading: §13.1

  1. Searching
    1. What it is
    2. Why it is an important problem
  2. Linear search
    1. Look at each element
    2. Unordered list: as good as any (see search-1.py)
    3. Ordered list: go until you pass where the value would be (see search-2.py)
  3. Binary search
    1. Ordered list only; how it works
    2. Example (see search-3.py)
  4. Comparison (see search-1c.py, search-2c.py, search-3c.py)