Navigation
index
next
|
previous
|
PLC 2025
»
Lecture Notes, Week 04
ΒΆ
Unit tests
The notion of unit test
Exercise 01
Solution for Exercise 01
Interlude
Exercise 02
Testing properties
Exercise 03
Exercise 04
And one more for the road
Resources
Version
From divergence to primitive iteration and primitive recursion
Resources
So, divergence
Bounding the number of self applications
Primitive iteration
Addition is primitive iterative
Multiplication is primitive iterative
Exponentiation is primitive iterative
Exercise 05
Primitive recursion
The factorial function is primitive recursive
Exercise 06
Exercise 07
Exercise 08
Resources
Version
Pairs, binary trees, and lists
Goal
Resources
Pairs
The challenge with pairs
Binary trees
A sample of binary trees of integers
Properties of binary trees of natural numbers
Towards computing the number of leaves of a given binary tree
Towards computing the number of nodes in a given binary tree
Interlude
The empty list
Lists
Proper lists
Predefined procedure to test for a proper list
Computing the length of a proper list
Concatenating a proper list to another proper list
Improper lists
Cyclic lists
Resources
Version
The Scheme programming language, continued
Goal
Resources
Core special form: quote
Derived special forms: let
Landin’s correspondence principle
Interlude
Let-expressions, continued
Lexical scope and local procedures
A concrete example of dynamic scope in Emacs Lisp
Core special forms: define, revisited
Derived special forms: let*
Resources
Version
Unit tests, revisited
Resources
Chez Scheme’s random-number generator
Exercise 09
Solution for Exercise 09
Exercise 10
Application to unit testing
Interlude
Exercise 11
Resources
Version
Exercises for Week 04
Exercise 00
Mandatory exercises
Exercise 12
Version
Index of concepts for Week 04
Version
Previous topic
Index of concepts for Week 03
Next topic
Unit tests
Quick search
Enter search terms or a module, class or function name.
Navigation
index
next
|
previous
|
PLC 2025
»