摘要: abs(x) 返回x的绝对值,x可以是integer/float型数。如果x是一个复数,则返回其模值。 x=-5 print(abs(x)) 5 x=3+4j print(abs(x)) 5 all(iterable) 如果iterable里面的元素都是true(或者为空),返回true.(iterable可以迭代的容器,数组、列表等) iterable=[1,2,3,4,5,6] prin... 阅读全文
posted @ 2015-05-07 22:20 iamaprin 阅读(148) 评论(0) 推荐(0) 编辑