From: Edi Weitz

Subject: Re: Length

Date: 2003-1-15 16:51

"feilong" <coli.uni-sb.de at feilong> writes:

> Hello, > Why is the length of (quote '(1 2 3)) 2 not 3. > For example: > CG-USER(3): (length (quote '(1 2 3))) > 2 > > CG-USER(5): (length ''(1 2 3)) > 2 > > CG-USER(6): (length '''(1 2 3)) > 2 > > CG-USER(7): (length ''''(1 2 3)) > > 2 > > Best Greeting
'(1 2 3) is just shorthand for (quote (1 2 3)), so (quote '(1 2 3)) could also be written as (quote (quote (1 2 3))) or '(quote (1 2 3)) which clearly is a list with two elements - the symbol QUOTE is the first element, and the list (1 2 3) is the second element. Cheers, Edi.