mirror of
https://github.com/opentffoundation/opentf.git
synced 2026-01-28 12:00:18 -05:00
Previously we just listed out all of the functions in alphabetical order inside the "Interpolation Syntax" page, but that format doesn't leave much room for details and usage examples. Now we give each function its own page, and categorize them for easier navigation. While many functions are very simple and don't really warrant a full page, certain functions do have additional details that are worth mentioning and this structure scales better for those more complicated functions. So far this includes only the numeric and string functions. Other categories will follow in subsequent commits.
28 lines
510 B
Markdown
28 lines
510 B
Markdown
---
|
|
layout: "functions"
|
|
page_title: "ceil function"
|
|
sidebar_current: "docs-funcs-numeric-ceil"
|
|
description: |-
|
|
The ceil function returns the closest whole number greater than or equal to
|
|
the given value.
|
|
---
|
|
|
|
# `ceil` Function
|
|
|
|
`ceil` returns the closest whole number that is greater than or equal to the
|
|
given value, which may be a fraction.
|
|
|
|
## Examples
|
|
|
|
```
|
|
> ceil(5)
|
|
5
|
|
> ceil(5.1)
|
|
6
|
|
```
|
|
|
|
## Related Functions
|
|
|
|
* [`floor`](./floor.html), which rounds to the nearest whole number _less than_
|
|
or equal.
|