JavaScript Math pow() methodThe JavaScript math pow() method returns the base to the exponent power such as baseexponent. In other words, the base value (x) is multiplied with itself exponent times (y). SyntaxThe pow() method is represented by the following syntax: ParameterBase - The base number. Exponent - The number used to raise the base. ReturnThe value of base to the power of exponent. JavaScript Math pow() method exampleHere, we will understand pow() method through various examples. Example 1Let's see a simple example to print the power of given number. Test it NowOutput: 8 9.518269693579391 Example 2Let's see an example to understand the pow() method with different test cases. Test it NowOutput: 0.125 9 NaN 0.1050611121761507 Example 3Let's understand the pow() method with your own test cases. Test it NowNext TopicJavaScript Math |
We provides tutorials and interview questions of all technology like java tutorial, android, java frameworks
G-13, 2nd Floor, Sec-3, Noida, UP, 201301, India