max()

max() 用于返回序列中的最大值,min() 用于返回序列中的最小值

In [1]: str = "hello world"

In [2]: max(str)
Out[2]: 'w'

In [3]: min(str)
Out[3]: ' '

    

猜你喜欢

转载自www.cnblogs.com/pzk7788/p/10186568.html
max