Example: Height of a Tree
lThe height of a tree is the length of the longest path from the root.

lheight(T) => isLeaf(T) ? 1;

lheight(T) => 1 + sum(map(height, getOffspring(T));

lLet recursion do the work for you.