Ceiling

The ceiling function maps a real number to the next largest or next smallest integer.

More precisely, ceiling(x) is the smallest integer not less than x.

img

Syntax :

Ceiling(Value)
Parameters Description
value Required number.

Examples:

Example 1

dCeil = Ceil(99.99999999) 
DEBUG(dCeil)

Result :

dCeil
= 100

Example 2

dCeil = Ceil(-0.99999999)
DEBUG(dCeil)

Result:

dCeil
= 0

Example 3

dCeil = Ceil(0) 
DEBUG(dCeil)

Result:

dCeil
= 0

Example 4

dCeil = Ceil(-1) 
DEBUG(dCeil)

Result :

dCeil
= -1

Example 5

dCeil = Ceil(-99.99999999)
DEBUG(dCeil)

Result :

dCeil
= -99