> For the complete documentation index, see [llms.txt](https://liuzhenglaichn.gitbook.io/algorithm/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://liuzhenglaichn.gitbook.io/algorithm/math/round-up.md).

# Round Up

Assume `A > 0` and `B > 0` are two integers, `ceil((double)A / B)` can be written as `(A + B - 1) / B`.
