Hi Jon,

> (de floor (X)
>       (let R (% X 1.0)
>               (if (lt0 R) (- X R 1.0) (- X R)) ) )
> 
> (de ceil (X)
>       (let R (% X 1.0)
>               (if (gt0 R) (+ (- X R) 1.0) (- X R)) ) )

Looks nice! I don't think there is a substantially better way.

Anybody else ?

Cheers,
- Alex

Reply via email to