On 2006-04-21, Pascal Bourguignon wrote:
> Peter Seibel writes:
>> <http://www.lispniks.com/faq/staging-faq.html>
>
> About CAR/CDR, perhaps this tree would be nice:
>
> tree
> / \
> / \
> / \
> / \
> CAR CDR
> / \ / \
> / \ / \
> / \ / \
> CAAR (*) CADR CDAR CDDR
> / \ / \ / \ / \
> CAAAR CAADR CADAR CADDR CDAAR CDADR CDDAR CDDDR
>
>
> Giving the position in the tree of each of the functions of the
> tree, eg. (*) is (CAAR tree).
That's a cool idea. But your tree is wrong. e.g. (cdr (car (car x)))
=> (cdaar x), not (caadr x).
tree
/ \
/ \
/ \
/ \
CAR CDR
/ \ / \
/ \ / \
/ \ / \
CAAR CDAR CADR CDDR
/ \ / \ / \ / \
CAAAR CDAAR CADAR CDDAR CAADR CDADR CADDR CDDDR
-- Larry
_______________________________________________
Gardeners mailing list
[email protected]
http://www.lispniks.com/mailman/listinfo/gardeners