('name','age','sex')'sex,age,name'>>> >>> '{2},{1},{1}'.format('name','age','sex')'sex,age,age'>>> #在Python3.5.1...版本中,如果format_spec不是一个空字符串,object()....__format__(format_spec) 将抛出一个TypeError异常。...要了解更多format的形式,请参考format的语法
all
all(iterable):如果iterable对象中所有内容都为True或内容为空,则返回True,否则返回False。...dir
不带参数时,返回上下文中范围内所有的属性。