Construction of symbolic expressions *
Construct the symbolic expressions illustrated on this page
via the cons
primitive in Scheme.
The entities named a
should be symbols. As a help, the rightmost part of the structure is made by (cons 'g 'h)
is equivalent to (quote g)
, meaning that g
is not evaluated, but taken for face value.
Experiment with h being the empty list. Try to use a proper list function, such as length, on your structures.