rational? ( object -- ? )


Vocabulary
math

Inputs and outputs
objectan object
?a boolean


Word description
Tests if the object is an instance of the rational class.

Definition
USING: kernel ;

IN: math

: rational? ( object -- ? )
dup ratio? [ drop t ] [ integer? ] if ;