Please note, this is a STATIC archive of website www.tutorialspoint.com from 11 May 2019, cach3.com does not collect or store any user information, there is no "phishing" involved.
Tutorialspoint

1 Answer
karthikeya Boyini

The hypot() function of the Math object accepts numbers and returns the square root of the sum of squares of the given numbers.

Syntax

Its Syntax is as follows

Math.hypot(12, 58, 66); 

Example

Live Demo

<html>
   <head>
      <title>JavaScript Example</title>
   </head>
   <body>
      <script type="text/javascript">
         var result = Math.hypot(12, 58, 66);
         document.write("hypot value: "+result); 
      </script>
   </body>
</html>

Output

hypot value: 88.67919710958147

Advertisements

We use cookies to provide and improve our services. By using our site, you consent to our Cookies Policy.