or (AutoLISP)

Returns the logical OR of a list of expressions

Supported Platforms: Windows and Mac OS

Signature

(or [expr ...])
expr

Type: Integer, Real, String, List, Subroutine, Ename (entity name), T, or nil

The expressions to be evaluated.

Remarks

The or function evaluates the expressions from left to right, looking for a non-nil expression.

Return Values

Type: T or nil

T, if a non-nil expression is found; otherwise nil, if all of the expressions are nil or no arguments are supplied.

Note that or accepts an atom as an argument and returns T if one is supplied.

Examples

(or nil 45 '())
T

(or nil '())
nil