摘要:
11.数学与随机数 (1)math包主要处理数学相关的运算。math包定义了两个常数: math.e # 自然常数e math.pi # 圆周率pi (2)math包运算 math.ceil(x) # 对x向上取整,比如x=1.2,返回2 math.floor(x) # 对x向下取整,比如x=1.2 阅读全文
posted @ 2022-01-23 18:19
肝
阅读(51)
评论(0)
推荐(0)
|
摘要:
11.数学与随机数 (1)math包主要处理数学相关的运算。math包定义了两个常数: math.e # 自然常数e math.pi # 圆周率pi (2)math包运算 math.ceil(x) # 对x向上取整,比如x=1.2,返回2 math.floor(x) # 对x向下取整,比如x=1.2 阅读全文
posted @ 2022-01-23 18:19
肝
阅读(51)
评论(0)
推荐(0)
|