max
Gives the largest of its arguments, or of the items of a list when a single list is given. Values are compared as numbers; an argument that is not a number is ignored. With nothing to compare, null.
Runs on: either side: the compiler places the statement that calls it where the values it uses live.
Format:
max(number1, number2 [, ...]) or max(list)
Parameters:
| Parameter | Type | Description |
|---|---|---|
| number1 | mixed | a number, or a list of numbers |
| number2 | number |  [Optional]further numbers |
Returned Value:
| Type | Description |
|---|---|
| number | the largest, or null |
Examples
page = max(1, min(page, pages))