Code for recitation 8 (abstraction functions & rep invariants, recursive datatypes)