2014年9月25日
摘要: 用途:用已知的列表生成一个新的列表list_comprehension.pyold_list = [5,6,7]new_list = [ 2*i for i in old_list if i%2]print new_list输出[10,14] 阅读全文
posted @ 2014-09-25 00:30 Sluggard 阅读(163) 评论(0) 推荐(0)