macros:Functions:ceil: Difference between revisions
Jump to navigation
Jump to search
(New page: ==Function ceil== Returns the number passed in if it is an integer, otherwise it returns the number rounded up to the next integer. ===Usage=== <source lang="mtmacro" line> [h: val = ceil...) |
(No difference)
|
Revision as of 13:13, 1 December 2008
Function ceil
Returns the number passed in if it is an integer, otherwise it returns the number rounded up to the next integer.
Usage
[h: val = ceil(num)]
[h: val = ceiling(num)]
Examples
[r: ceil(10)]
Returns 10.
[r: ceil(1.2)]
Returns 2.
[r: ceil(-1.2)]
Returns -1.