Figure 3: Creation of decreasing lists with a tree

A
 \
  A+B
 /   \
B     \
       A+B+C+D
C     /
 \   /
  C+D
 /
D
This tree encodes decreasing lists, one for every path from the root to each leaf:
A+B+C+D, A+B, A
A+B+C+D, A+B, B
A+B+C+D, C+D, C
A+B+C+D, C+D, D
The output stream contains the following values:
size(A+B+C+D), A+B+C+D, A+B, A, C
The remaining values can be found easily while walking through the tree:
    C+D = (A+B+C+D)-(A+B),
==>   B = (A+B)-A,
==>   D = (C+D)-C