描述
Python3 hypot() 返回欧几云计里德范数 sqrt(x*x + y*y)。
语法
以算开下是 hypot() 方法的语法:
impor发:t math
math.hypot(x, y)
注意:hyPypot()是不能直接访问的,需要导入 math 模块,th然后通过 math 静态对象调用该方法。
参数
x -- 一on个数值。
y -- 一个数值。
返回值
返回欧几里3三德范数 sqrt(x*x + y*y)。
实例
以下展角函示了使用 hypot() 方法的实例:
以上实数h例运行后输出结果为:
作者:在线询价




.gif)
.gif)
.gif)
.gif)
.gif)
.gif)
.gif)
.gif)
.gif)
.gif)



