% dim title title = "CS2110 F09 Lecture Notes" %> <% dim rowParity rowParity = 1 %>
Readings refer to the course text: Data Structures and Abstractions with Java, 2nd edition by Frank M. Carrano, Prentice Hall, 2007. ISBN 0-13-237045-X. See also the Prentice Hall website for additional material.
Note: Professor Birman is posting the Fall 2008 lecture notes for lectures that he hasn't had time to revise yet. As the date of a lecture approaches, he may revise the posted material and hence the version given in class may not be posted until the day of the class. The content won't depart drastically from what you see below, but the specific slides could be quite different for some lectures. So we don't recommend printing these in advance, or at least if you do, don't be surprised when some lectures depart from what you printed. Hint: the new slides use a new design, so you can recognize them easily. Also, the lecture dates are off by one day for the old slides -- Sept. 3 will show as Sept 4, for example. As Professor Birman revises and reposts the slides, he also fixes things like the date shown for the lecture.
| LECTURE | DATE | TOPICS | NOTES/EXAMPLES | READING | |
|---|---|---|---|---|---|
| 1. | Introduction | 8/27 |
Course policies and procedures 2110 and 2111 A motivating application Why this course is important |
Lecture Notes Lecture Notes (6up) Software Article Sam Loyd Proof The 15 Puzzle About Sam Loyd |
Chapter 1 Appendix A |
| 2. | Java Review | 9/1 |
Brief programming language history Basic Java/OO concepts Tour of the Java API Java tips, tricks, and pitfalls Type hierarchy and subtyping Inheritance Method overriding Debugging |
Lecture Notes Lecture Notes (6up) CommandLineArgs.java Enum.java Equals.java FileIO.java Generics.java MultiArray.java Widget.java ShadowTest.java ConstructorSuper.java ConstructorThis.java SuperMethod.java |
Chapter 2 Appendix B Appendix C |
| 3 | Software Design Principles I merged with lecture 5 and presented on 9/10 |
9/3 |
Top-Down, Bottom-Up Design Software Process (briefly) Modularity Information Hiding, Encapsulation Principles of Least Astonishment and “DRY” Refactoring |
Lecture Notes Lecture Notes (6up) |
|
| 4. | Interfaces and Types | 9/8 |
Interfaces Abstract classes Static vs dynamic types Up- and downcasting Maintaining abstraction boundaries |
Lecture Notes Lecture Notes (6up) |
Chapter 3 |
| 5. | Software Design Principles II | 9/10 |
Test-driven development and JUnit Incremental development |
Lecture Notes Lecture Notes (6up) SmallSet.java SmallSetFullException.java SmallSetTest.java |
|
| 6. | Recursion | 9/15 |
Recursive programs Stack frames and recursive calls The induction principle |
Lecture Notes Lecture Notes (6up) Power.java HanoiRecursive.java HanoiIterative.java |
Chapter 10 |
| 7. | Grammars and Parsing | 9/18 |
Grammars Parsing |
Lecture Notes Lecture Notes (6up) SimpleExpression.java SimpleExpressionCodeGenerator.java |
Appendix B |
| 8. | Lists | 9/22 |
Singly-linked lists Building and searching Insertion and deletion Doubly-linked lists |
Lecture Notes Lecture Notes (6up) List.java ArrayList.java LinkedListIterative.java LinkedListRecursive.java ListTest.java |
Chapters 4-7 |
| 9. | Trees | 9/24 |
Tree implementations Binary Search Trees (BSTs) Tree traversals |
Lecture Notes Lecture Notes (6up) BST.java BSTTest.java BSP.jar |
Chapters 25-27 |
| 10. | GUI Statics | 9/30 |
Components Containers Layout managers |
Lecture Notes Lecture Notes (6up) Intro.java Basic1.java Basic2.java Calculator.java ComponentExamples.java LayoutDemo.java Statics1.java Statics2.java Statics3.java |
Swing Tutorial |
| 11. | GUI Dynamics | 10/2 |
Event-driven programming Java event model Events Listeners Adapters |
Lecture Notes Lecture Notes (6up) Example1.java ListenerExample1.java ListenerExample2.java ListenerExample3.java AdapterExample.java Scribble.java |
Swing Tutorial |
| 12. | Searching and Asymptotic Complexity | 10/6 |
Linear vs Binary Search Runtime analysis Big-O Worst-case and expected-case |
Lecture Notes Lecture Notes (6up) Search.java SearchTest.java |
Chapter 16 |
| 13. | Sorting | 10/8 |
Insertion Sort Selection Sort Merge Sort Quick Sort Stable sorting Lower bound for comparison sorts |
Lecture Notes Lecture Notes (6up) Sorter.java InsertionSort.java SelectionSort.java MergeSort.java QuickSort.java SortTest.java |
Chapters 11, 12 |
| Fall Break | 10/13 | no lecture | |||
| 14. | Generic Types and Java Collections | 10/15 |
Generic types Java Collections Framework |
Lecture Notes Lecture Notes (6up) |
Java API |
| 15. | Software Design Principles III | 10/20 |
Contracts (pre- and postconditions) Pair programming Duplication of state Sanity checks and the Java assert statement The design/code/debug cycle Javadoc Error handling Design Patterns |
Lecture Notes Lecture Notes (6up) Observable.java Observer.java ObserverTest.java TreeNode.java Visitor.java VisitorTest.java |
|
| 16. | Standard ADTs | 10/22 |
Stacks Queues Dictionaries Hashtables |
Lecture Notes Lecture Notes (6up) |
Chapters 17-22 |
| 17. | Priority Queues and Heaps | 10/27 |
Priority Queues Heaps |
Lecture Notes Lecture Notes (6up) |
Chapters 23, 24, 28 |
| 18. | Graphs I | 10/29 |
Graphs Topological sort Coloring, Planarity DFS BFS Dijkstra's Algorithm |
Lecture Notes Lecture Notes (6up) |
Chapters 30, 31 |
| 19. | Graphs II | 11/3 |
Dijkstra's algorithm Minimum spanning trees Prim's algorithm |
Lecture Notes Lecture Notes (6up) Digraph.java |
Chapters 30, 31 |
| 20. | Threads and Concurrency I | 11/5 |
Java threads The event dispatch thread Locking and synchronization |
Lecture Notes Lecture Notes (6up) |
|
| 21. | Threads and Concurrency II |
11/10 |
More on races and critical sections. Wait/notify, producer-consumer example Concurrent BST put/get example |
Lecture Notes Lecture Notes (6 up) |
|
| 22. | Induction | 11/12 |
The Induction Principle Induction and Recursion |
Lecture Notes Lecture Notes (6up) |
|
| 23. | Proving correctness of concurrent programs using linearizability, induction | 11/17 |
Safety, liveness Linearizability Inductive proofs of deadlock-freedom |
Lecture Notes Lecture Notes (6up) |
|
| 24. | The Java Virtual Machine I | 11/19 |
Platform independence Class file format Bytecode examples Class loading and initialization Object initialization |
Lecture Notes Lecture Notes (6up) BytecodeExamples.zip |
|
| 25. | The Java Virtual Machine II | 11/24 |
Instance Method Dispatch Exception Handling The Java Security Model Bytecode Verification Stack Inspection |
Lecture Notes Lecture Notes (6up) |
Some papers on stack inspection: Erlingsson Fournet Wallach |
| Thanksgiving | 11/26 |
|
Recipes for your Thanksgiving dinner. |
||
| 26. | Distributed Systems | 12/1 | How Java is used to build client/server systems. How does a networked application differ from a distributed one? |
Lecture Notes Lecture Notes (6up) |
|
| 27. | Cloud Computing | 12/3 | The big web sites are run by massive computer data centers. What issues does this raise? |
Lecture Notes Lecture Notes (6up) |
|