Calculate the hypotenuse of different right-angle triangles:
The hypot() function calculates the hypotenuse of a right-angle triangle.
Tip: This function is equivalent to sqrt(x*x + y*y).
Parameter | Description |
---|---|
x | Required. Specifies the length of first side |
y | Required. Specifies the length of second side |
Return Value: | The length of the hypotenuse |
---|---|
Return Type: | Float |
PHP Version: | 4.1+ |