Equality and Conditional Functions
 
 
 

The following table provides summary descriptions of the AutoLISP equality and conditional functions.

Equality and conditional functions

Function

Description

( = (equal to)numstr [numstr] ...)

Returns T if all arguments are numerically equal, and returns nil otherwise

( /= (not equal to)numstr [numstr] ...)

Returns T if the arguments are not numerically equal, and nil if the arguments are numerically equal

( < (less than)numstr [numstr] ...)

Returns T if each argument is numerically less than the argument to its right, and returns nil otherwise

( <=(less than or equal to)numstr [numstr] ...)

Returns T if each argument is numerically less than or equal to the argument to its right, and returns nil otherwise

( > (greater than)numstr [numstr] ...)

Returns T if each argument is numerically greater than the argument to its right, and returns nil otherwise

( >=(greater than or equal to)numstr [numstr] ...)

Returns T if each argument is numerically greater than or equal to the argument to its right, and returns nil otherwise

( and [expr ...])

Returns the logical AND of a list of expressions

( Boolefunc int1 [int2 ...])

Serves as a general bitwise Boolean function

( cond [(test result ...) ...])

Serves as the primary conditional function for AutoLISP

( eqexpr1 expr2)

Determines whether two expressions are identical

( equalexpr1 expr2 [fuzz])

Determines whether two expressions are equal

( iftestexpr thenexpr [elseexpr])

Conditionally evaluates expressions

( or [expr ...])

Returns the logical OR of a list of expressions

( repeatint [expr ...])

Evaluates each expression a specified number of times, and returns the value of the last expression

( whiletestexpr [expr ...])

Evaluates a test expression, and if it is not nil, evaluates other expressions; repeats this process until the test expression evaluates to nil