摘要: 1. 利用map和reduce编写一个str2float函数,把字符串'123.456'转换成浮点数123.456: from functools import reduce def str2num(s): return {'0': 0, '1': 1, '2': 2, '3': 3, '4': 4 阅读全文
posted @ 2017-07-09 19:19 hukey 阅读(340) 评论(0) 推荐(0)