Structural Informatics Group (SIG) logo
Home | Projects | Demos | Downloads | Publications | Local Info | About Us | New site
Go to the first, previous, next, last section, table of contents.

minusp

minusp

type: predicate function (subr)
location: built-in
source file: xlmath.c
Common LISP compatible: yes
supported on: all machines

SYNTAX

(minusp <expr> )
        <expr>          -       the numeric expression to check

DESCRIPTION

The MINUSP predicate checks to see if the number <expr> is negative. T is returned if the number is negative (less than zero), NIL is returned otherwise. A bad argument type error is generated if the <expr> is not a numeric expression.

EXAMPLES

(minusp 1)                              ; returns NIL
(minusp 0)                              ; returns NIL
(minusp -1)                             ; returns T
(minusp -.000000005)                    ; returns T
(minusp #xFFFFFFFF)                     ; returns T
(minusp #x01)                           ; returns NIL
                                        ;
(minusp 'a)                             ; error: bad argument type
(setq a -3.5)                           ; set A to -3.5
(minusp a)                              ; returns T


Go to the first, previous, next, last section, table of contents.