一.列表(list) 1.列表的格式 li = [11,22,"kobe",["lakers","ball",11],(11,22,),{"k1":11,"k2":"kuzma"},True,False] 2.列表可以嵌套任何格式,数字.字符串.列表.元组.字典.布尔值. 3.索引取值 li = [11,22,"kobe",["lakers",&q…
import types aaa = 0 print type(aaa) if type(aaa) is types.IntType: print "the type of aaa is int" if isinstance(aaa,int): print "the type of aaa is int" bbb = 'hello' print type(bbb) if type(bbb) is types.StringType: print "the t…