Re: Help with "facing" routine

new topic     » goto parent     » topic index » view thread      » older message » newer message

At 05:16 PM 7/1/98 +0200, you wrote:
>I would like to thank for all help with this routine, now it works
>perfectly. I have not decided which routine to use yet, I will have to speed
>test them first. Right now I use the one given by Jiri because it has the
>least lines of code.
>
>There is one thing in the mail from Lithex I would like to point out:
>
>> function Int(object x) return(x-remainder(x,1)) end function
>
>Instead, you can just use the built-in floor(). Probably faster.
>
>Einar
>

They're a bit different.  Floor always rounds down, while int always rounds
towards 0, so:

floor({1.2,-1.2})  =>  {1,-2}
int({1.2,-1.2})    =>  {1,-1}

new topic     » goto parent     » topic index » view thread      » older message » newer message

Search



Quick Links

User menu

Not signed in.

Misc Menu