描述
Python3 cos() 返回x的弧度云计的余弦值。
语法
以下是 cos() 方法的语法:
i算开mport math
math.cos(x)
注意:发:cos()是不能直接访问的,需要导入 math 模块Py,然后通过 math 静态对象调用该方法。
参数
xth -- 一个数值。
返回值
返回x的弧度的余弦值,-1on 到 1 之间。
实例
以下展示了使用 cos() 方法的实3三例:
以上实例运行后输出结果为:
邮箱:[email protected]
电话:020-123456789
传真:020-123456789
Copyright © 2026 Powered by 知恩报德网 http://trading-records.com/