Next: , Previous: , Up: Numbers   [Contents][Index]


5.4.2 Numeric Predicates

Don’t use eq for equality test of numbers. Instead, use eql or equal. See Equality Predicates.

For the documentation of the functions =, /=, >, <, >=, <=, max and min, see Comparison Predicates.

Function: exactp object

Returns true when object is an exact number.

Function: inexactp object

Returns true when object is an inexact number.

Function: integerp object

Returns true when object is an integer.

Function: rationalp object

Returns true when object is a rational number (including integers).

Function: realp object

Returns true when object is a real number.

Function: oddp x

Return true if x is an odd number.

Function: evenp x

Return true if x is an even number.

Function: positivep x

Return true if x is a number greater than zero.

Function: negativep x

Return true if x is a number less than zero.

Function: zerop x

Returns true if x is equal to zero.