functools.partial(sorted, key = str.upper)句中 key = str.upper的用法是?
import functools sorted_ignore_case = functools.partial(sorted, key = str.upper) print sorted_ignore_case(['bob', 'about', 'Zoo', 'Credit'])
求问 functools.partial(sorted, key = str.upper)
这句中 key = str.upper如何理解?