chickadee » math » fpsgn

fpsgn xprocedure
fpeven? xprocedure
fpodd? xprocedure
x
flonum

Like sgn, even?, and odd?, but restricted to flonum input.

Examples:

> (map fpsgn '(-2.0 -0.0 0.0 2.0))
'(-1.0 0.0 0.0 1.0)
> (map fpeven? '(2.0 1.0 0.5))
'(#t #f #f)
> (map fpodd? '(2.0 1.0 0.5))
'(#f #t #f)