2013年10月12日

python字典作为统计记录工具

摘要: 1.python 利用字典作为计数项,统计指定项的个数 #!/usr/bin/python ta={} key = "test" if not key in ta: ta["test"]=0 for i in range(1,5): ta["test"] += 1 print ... 阅读全文

posted @ 2013-10-12 17:16 代码王子 阅读(412) 评论(0) 推荐(0)

导航