Lecture notes for Week 7: Trees and Priority Queues

Topics

  1. Trees

  2. Binary trees

  3. Priority Queues

Textbook portions covered

Introduction to Algorithms (Cormen et al.)

Apppendix B.5

Chapter 6

Engineering Algorithms...(Clowes “online book”)

Chapter 7

Lecture 19 (Friday, February 18, 2005)

Announcements

  • Study Week next week.
  • Midterm Friday March 4

Overview of heaps

  1. Covered: binary trees, complete binary trees, array representation, heap, informal overview of add/delete and heapSort (O(n log n)).

Lecture 20/21 (Tuesday, March 1, 2005)

Announcements

  • Midterm FRIDAY!

Suggested Problems

Introduction to Algorithms (Cormen et al.)
  • Exercise B.5-1
  • Exercise B.5-3
  • Exercise 6.5-1
  • Exercise 6.5-2
  • Exercise 6.5-6
Engineering Algorithms...(Clowes “online book”)
  • 7.1
  • 7.2
  • 7.5

by Ken Clowes

v1.0