previous up next
Go backward to Consequence
Go up to Top
Go forward to Example
RISC-Linz logo


Take the set List(T) defined in the previous example and assume that it is a term algebra. We define the length of a list as

length: List(T) -> N
length(nil) := 0
length(cons(e, l)) := 1+length(l).

Then we have length(cons(1, cons(2, nil))) = 2.

Author: Wolfgang Schreiner
Last Modification: November 24, 1999

previous up next