GLBasic forum

Main forum => GLBasic - en => Topic started by: bigsofty on 2016-Nov-09

Title: FLOOR()
Post by: bigsofty on 2016-Nov-09
Undocumented? Seems to be present but not in the docs?

Handy to have all the same.  ;)
Title: Re: FLOOR()
Post by: erico on 2016-Nov-09
what does it do?
Title: Re: FLOOR()
Post by: Kitty Hello on 2016-Nov-09
Cut post-decimal sign figures.
Floor(9.999) is 9.0
Title: Re: FLOOR()
Post by: Kitty Hello on 2016-Nov-09
Ceil rounds to the next full integer. Ceil(1.01) is 2.0
Title: Re: FLOOR()
Post by: erico on 2016-Nov-09
Nice...it does look like the things that could help me a lot on a couple fronts, thanks! :good:
Title: Re: FLOOR()
Post by: spacefractal on 2016-Nov-09
FLOOR() is same as INTEGER()? Im have used INTEGER() various time.

This hence its been undocumented.
Title: Re: FLOOR()
Post by: bigsofty on 2016-Nov-10
Mathematicaly Floor() rounds down, INTEGER() truncates. This is especially evident when you use negative floating point numbers. Try -4.6 in both and you should get different results.