Syntax
- float max(a, b)
Parameters
- a—float or stringb must have the same type.
- b—float or stringa must have the same type.
Returns
Returns maximum of a and b.
Description
The max function finds the maximum of a and b. It also works if a and b are strings.
Related
Examples
example.1
max(10, -10)
# result = 10
example.2
max("abc", "def")
# result = "def"