COS 126 Lectures, Spring 2001

The following table contains links to the course packet lecture notes, precept notes, and in-class demos.

Lecture Notes Precept Notes In-class Demos
I1.   Introduction  
LFBSR applet LFBSR demo
P1.   Introduction to C
variables basic ops
conditions loops
P2.   Arrays arrays
C code Insertion sort
P3.   Unix  
C and Unix code
P4.   Structs structs
C code
P5.   Abstract data types
modular programming
ADTs: stacks and queues
C code Stack of plates
Stack array Postfix
PostScript Queue array
P6.   Recursion I
functions recursion
variable scope
C code Function calls
Recursive sum Bisection
Hanoi applet
P7.   Recursion II  
C code Partitioning
Quicksort Permutations
A1.   TOY machine  
TOY applet
A2.   TOY programming  
TOY applet 2's complement
A3.   Boolean circuits
Boolean circuits
Circuit applet Hydraulic OR
A4.   Sequential circuits
sequential circuits
Circuit applet
A5.   Machine organization    
Advanced Programming 
P8.   Pointers and linked lists
pointers linked lists
C code Pointer
Bad swap Swap
Static list Dynamic list
P9.   WAR card game  
C code Deal
P10. Binary search trees
BSTs strings
Binary search BST applet
BST search BST insert
Preorder Level order
Theory of Computation 
T1.   Pattern matching
RE grep
10(10)* FSA acat FSA
grep examples
T2.   Machines
NFSA 1 (naive) (systematic)
NPDA Turing 1
Turing 2
T4.   Computability computability
PCP Contest
T5.   Algorithms and sorting  
Insertion sort Merge
Partition WinSort
T6.   NP-completeness NP-completeness  
S1.   Java  
example code
S2.   Operating systems    
S3.   Networking   java socket code
R1.   Course wrapup  
Course objectives

How to read the files.

Get Aladdin GSView 6.01 Get Acrobat Reader Get Java 1.3 plug-in Get Microsoft Products

Content subject to change.

Any significant changes or corrections to the slides will be noted in the course announcements. You are responsible for the information in the (most up to date) electronic versions.


The lecture note material was created by Robert Sedgewick. Some of the lectures have been adapted by Kevin Wayne and Randy Wang. There are also notes on various topics covered in precept, written by Lisa Worthington.

Copyright © 2001, Robert Sedgewick