15-150: Principles of Functional Programming

Lecture 4: Recursion and Structural Induction on Lists, Tail Recursion

Key Concepts

Sample Code

Some Notes on Structural Induction

(Those notes also discuss two concepts that we have not yet discussed: datatype declarations and structural induction over trees; we will see these in the next lecture.)

Proof of an extensional equivalence for two implementations of list reversal

Lecture Slides

Lecture Slides with every build, use "slideshow" option in your pdf viewer. Lecture Slides compact.