array ( 0 => 'index.php', 1 => 'PHP Manual', ), 'head' => array ( 0 => 'UTF-8', 1 => 'uk', ), 'this' => array ( 0 => 'function.hypot.php', 1 => 'hypot', 2 => 'Calculate the length of the hypotenuse of a right-angle triangle', ), 'up' => array ( 0 => 'ref.math.php', 1 => 'Функції Math', ), 'prev' => array ( 0 => 'function.hexdec.php', 1 => 'hexdec', ), 'next' => array ( 0 => 'function.intdiv.php', 1 => 'intdiv', ), 'alternatives' => array ( ), 'source' => array ( 'lang' => 'en', 'path' => 'reference/math/functions/hypot.xml', ), 'history' => array ( ), ); $setup["toc"] = $TOC; $setup["toc_deprecated"] = $TOC_DEPRECATED; $setup["parents"] = $PARENTS; manual_setup($setup); contributors($setup); ?>

hypot

(PHP 4 >= 4.1.0, PHP 5, PHP 7, PHP 8)

hypot Calculate the length of the hypotenuse of a right-angle triangle

Опис

hypot(float $x, float $y): float

hypot() returns the length of the hypotenuse of a right-angle triangle with sides of length x and y, or the distance of the point (x, y) from the origin. This is equivalent to sqrt($x*$x + $y*$y).

Параметри

x

Length of first side

y

Length of second side

Значення, що повертаються

Calculated length of the hypotenuse