Caml
Power
Power
Schedule
Warning: The schedule may change slightly; refresh your browser every week or so!
Dates | Topic | Notes/Code | Reading | |
---|---|---|---|---|
The Basics | ||||
W Sep 4 | OCaml Introduction | Intro, hello.ml, sum.ml | Functional Basics, Type Checking, Optional: RWO pp 1-10 | |
Sep 5-6 | Precept 1: OCaml Intro | precept1.zip ticket.ml .merlin fizzbuzz.ml (fizzbuzz solution) exercise1.ml | ||
M Sep 19 | Simple Immutable Data: Variables, Tuples, Options | Let, Functions, Tuples | Type-directed Programming; Optional: RWO Chap 2 |
|
Tu Sep 10 | Assign 1 Due | |||
W Sep 11 | Thinking Inductively | Options, Lists, Sort, Java Rant |
Thinking Inductively; Optional: RWO Chap 3 |
|
Sep 12-13 | Precept 2: Lists, Options, Polymorphism | precept2.zip precept2_solutions.zip | ||
M Sep 16 | Poly-HO: Polymorphism and Higher-Order Programming | C rant, map/reduce, Poly HO! | Polymorphism and Higher-order Programming | |
Tu Sep 17 | Assign 2 Due | |||
W Sep 18 | More Data! | Datatypes, gml.ml | Optional: RWO Chapter 6 | |
Sep 19-20 | Precept 3: Assignment 3, Map, Fold and Datatypes | precept3.zip; exercise3_sol.ml | ||
Reasoning About Programs | ||||
M Sep 23 | Building Interpreters | Abstract syntax, Substitution and evaluation | Operational Semantics | |
Tu Sep 24 | Assign 3 Due | |||
W Sep 25 | More Interpreters | Model of OCaml, Assignment 4; simple interpreter code: eval0.ml; with recursive functions: eval3.ml | ||
Sep 26-27 | Precept 4: Assignment 4 and More About Closures | precept4.zip; precept4_sol.zip |
||
M Sep 30 | How OCaml uses memory | Space model (and pruning closures); simple interpreter code: eval0.ml; with recursive functions: eval3.ml | ||
W Oct 2 | Proving Programs Correct | Simple proofs, Induction for naturals, Induction for lists | Equational Reasoning | |
Oct 3-4 | Precept 5: Mutually Recursive Types, Equational Reasoning | theorems.ml; exercise4.ml (#4) (Sample solution, with proofs); exercise5.ml (solution) |
||
M Oct 7 | More Correctness Proofs | Induction for datatypes, Proofs about programming languages | Equational reasoning about data types
Optional Reading: Odd-Order Theorem; Four-Color Theorem |
|
Tu Oct 8 | Assign 4 Due | |||
W Oct 9 | Generalizing your Induction Hypothesis | Generalized induction hypotheses; OCaml as compiled | ||
Oct 10-11 | Precept 6: Tail Recursion and More Equational Reasoning | |||
Oct 16-20 | Fall break | |||
Modularity | ||||
M Oct 21 | ML Modules | Simple modules, Design choices | Optional: RWO Chap 4 (Modules), 9 (Functors) | |
W Oct 23 | Midterm Exam Part I (in lecture) | |||
Th Oct 24 | Midterm Exam Part II (7:30pm) | |||
M Oct 28 | Modules and Assignment 5 |
Functors, Module evaluation
(continuing the slide deck from last week) |
||
W Oct 30 | Reasoning about Modules | Representation Invariants | Optional: Abstraction and Representation Invariants | |
Oct31-Nov1 | Precept 8: Modules | precept8.zip ; precept8_sol.zip | ||
M Nov 4 | Module Equivalence | Module Equivalence | ||
Mutation & Laziness | ||||
W Nov 6 | Mutation | Mutable References | Optional: RWO Chapter 8 | |
Nov 7-8 | Precept 9: Reasoning about Modules | range.mli; exercise9.txt (Solution) |
||
M Nov 11 | Functional programming in industry | Dr. Chris Casinghino, Jane Street | Watch in advance: Caml Trading | |
W Nov 13 | Lazy Evaluation | Laziness and Streams | ||
Nov 14-15 | Precept 10: Laziness & Monads | |||
M Nov 18 | Computability | Computability | Optional reading: The Birth of Computer Science at Princeton in the 1930s | |
Tu Nov 19 | Assign 5 Due | |||
W Nov 20 | Type Checking | Type Systems, Type Checking | ||
Nov 21-22 | Precept 7: Exam Prep | [yes, this precept is numbered out of order]] | ||
M Nov 25 | Type Inference | Type inference | Optional: Efficient Type Inference | |
T Nov 26 | No precepts today, even though registrar says Friday precepts will supposedly meet. | |||
Thanksgiving Break | ||||
Type Systems | ||||
Parallelism and Concurrency | ||||
M Dec 2 | Parallel Collections | Parallel Sequences | Parallel Sequences, Optional Reading: MapReduce; NESL | |
Tu Dec 3 | Assign 6 Due | |||
W Dec 4 | Parallel Collections II | Parallel Prefix Scan; Assignment 7 | ||
Dec 5-6 | Precept 11: Parallel map/reduce | precept11.zip | ||
Friday precepts will meet on December 6th, even though it's reading period. | ||||
Th Dec 12 | Assign 7 Due | |||
Dec 17 | Final Exam (3 hours) |