摘要:
# 具名元组>>> from collections import namedtuple >>> City = namedtuple('City', 'name country population coordinates') ➊ >>> tokyo = City('Tokyo', 'JP', 36 阅读全文
摘要:
len():容器中项目数量 Return the length (the number of items) of an object. The argument may be a sequence (string, tuple or list) or a mapping (dictionary). 阅读全文