Java Math.hypot() methodThe java.lang.Math.hypot() is used to return the square root of the sum of squares of the specified arguments without intermediate overflow or underflow. SyntaxParameterReturn
It returns the sqrt(x2 + y2) without intermediate overflow or underflow.
Example 1Test it NowOutput: 10.0 Example 2Output: 5.0 Example 3Test it NowOutput: Infinity Example 4Test it NowOutput: NaN
Next TopicJava Math
|