# [`⌈`](https://bpl.fast.ai//glyphs/upstile.html) — Ceiling / Maximum

Function. Keys: `Alt-s`. Hanzi: `上`. Ranks: `0` monadic, `0 0` dyadic

`⌈Y` rounds real numbers up. Pervasive; tolerant near integers. Under dynamic kinds, real float results become ordinary machine integers. Under static kinds they remain floats. `⌈ₓY` gives ordinary machine integers under both kinds. Exact numbers stay exact.

An integer result is clamped to the integer range: [`∞`](https://bpl.fast.ai//glyphs/infinity.html) gives its maximum, `¯∞` its minimum, and NaN gives zero. See [Static kinds](../numbers.md#static-kinds) for the integer width.

Complex ceiling is `-⌊-Y`, using [complex floor's](downstile.md) Gaussian-integer rule.

```bpl
⌈1.2 ¯1.2         ⍝ [2 ¯1]ₓ
⌈3r2              ⍝ 2ᵣ
```

`X⌈Y` takes the real maximum, and for characters the one with the higher code point. A character is greater than any number, as [`⍋`](delta-stile.md) orders them. Pervasive. Beside NaN it gives NaN or the other argument. Which one can vary by platform. A reduction, scan, window or inner product by [`⌈`](https://bpl.fast.ai//glyphs/upstile.html), or a write by `⌈←` to one position more than once, gives NaN or the greatest of the items that aren't NaN, `¯∞` where there are none, and never another number. Empty reduction identity: `¯∞`.

```bpl
3⌈1 5             ⍝ 3 5
"abc"⌈"bab"       ⍝ "bbc"
3⌈'a'             ⍝ 'a'
```
