JavaScript Powering a Number

To get the power of a number in JavaScript, the Math.pow() function is used.

The function takes 2 parameters. The first parameter is base number and the second parameter is force.

Let's examine the examples below..

The results will be like this...



You May Interest

What is go Method of History Object in Javascript ?

What is Prototypal Inheritance in Javascript ?

What is Code Smell in Javascript ?

What is this Keyword in Javascript ?

What are Asynchronous Scripts in Javascript ?