.. _ceiling: ======= ceiling ======= Rounds up to the next highest integer Description ~~~~~~~~~~~ The fn:ceiling function returns the smallest integer that is not less than $arg. The result type depends the numeric type of the argument. If $arg is untyped, it is cast to xs:double. .. list-table:: :widths: 40 60 :header-rows: 1 * - **Parameters** - **Description** * - arg:numeric() - Examples ~~~~~~~~ .. list-table:: :widths: 50 50 :header-rows: 1 * - **XPath** - **Results** * - ceiling(5) - 5 * - ceiling(5.1) - 6 * - ceiling(5.5) - 6 * - ceiling(-5.5) - -5 * - ceiling(-5.51) - -5 * - ceiling( () ) - () See Also ~~~~~~~~ .. toctree:: :titlesonly: :glob: * :ref:`floor`. * :ref:`round`. * :ref:`round-half-to-even`.