round()与abs()

xiaoxiao2021-02-28  53

round 函数很简单,对浮点数进行近似取值,保留几位小数。

round(10/3,33)

3.3333333333333335

abs()用于取绝对值

abs(4+3j) #abs中复数参数的表示

转载请注明原文地址: https://www.6miu.com/read-2621442.html

最新回复(0)