Python3 max() Method
Description
The max() method returns the largest letter in a string.
Syntax
max() method syntax:
max(str)
Parameters
- str -- a string.
Return Value
Returns the largest letter in the string.
Example
The following example shows how to use the max() function:
#!/usr/bin/python3
str = "runoob"
print ("最大字符: " + max(str))
The output of the above example is:
最大字符: u
Python3 Strings