listp

AutoCad AutoLISP Functions

 
listp
 
 
 

Verifies that an item is a list

(listp item)

Arguments

item

Any atom, list, or expression.

Return Values

T if item is a list; otherwise nil. Because nil is both an atom and a list, the listp function returns T when passed nil.

Examples

Command: (listp '(a b c))

T

Command: (listp 'a)

nil

Command: (listp 4.343)

nil

Command: (listp nil)

T

Command: (listp (setq v1 '(1 2 43)))

T

See Also