Algorithms and Data Structures


Algorithms and Data Structures PPT PDF SLIDES

Description. This course surveys the most important algorithms and data structures in use on computers today. Particular emphasis is given to algorithms for sorting, searching, and string processing. Fundamental algorithms in a number of other areas are covered as well, including geometric and graph algorithms. The course will concentrate on developing implementations, understanding their performance characteristics, and estimating their potential effectiveness in applications.

Course website. The course website
http://www.princeton.edu/~cos226
includes links to course content, including programming assignments, exercises, lecture slides, and old exams. You will also use it to submit programming assignments. Readings. The following textbook is required. It contains a wealth of information beyond what we can cover in lecture; it is certain to enhance your understanding of algorithms and data structures.
  • Algorithms, 4th Edition by Robert Sedgewick and Kevin Wayne, Addison-Wesley Professional, 2011, ISBN 0-321-57351-X.
Slides download here:

TOPICSLIDESREADINGSDEMOS
Intro · Union Find1up · 4up1.5Quick-union
Analysis of Algorithms1up · 4up1.4Binary search
Stacks and Queues1up · 4up1.3Dijkstra 2-stack
Elementary Sorts 1up · 4up2.1Selection · Insertion · Shuffle · Graham
Mergesort1up · 4up2.2Merging
Quicksort1up · 4up2.3Partitioning
Priority Queues1up · 4up2.4Heap · Heapsort
Elementary Symbol Tables · BSTs1up · 4up3.1–3.2BST
Geometric Applications of BSTs 1up · 4upKd tree · Interval search tree
Balanced Search Trees 1up · 4up3.3Red-black BST · GrowingTree
Hash Tables 1up · 4up3.4
Midterm Exam
Undirected Graphs1up · 4up4.1DFS · BFS
Directed Graphs1up · 4up4.2DFS · Topological sort
Minimum Spanning Trees1up · 4up4.3Greedy · Kruskal · Prim
Shortest Paths1up · 4up4.4Dijkstra · Acyclic · Bellman-Ford
Maximum Flow1up · 4up6.4Ford-Fulkerson
String Sorts1up · 4up5.1Key-indexed counting · String sorts
Tries1up · 4up5.2Trie
Substring Search1up · 4up5.3KMP
Regular Expressions 1up · 4up5.4NFA simulation · NFA construction

Data Compression1up · 4up5.5Huffman · LZW
Reductions1up · 4up
Combinatorial Search1up · 4upThe Longest Path