tylermwashburn tylermwashburn - 4 months ago 22
Javascript Question

JavaScript exponents

How do you do exponents in JavaScript?

Like how would you do 12^2?

Answer

Math.pow():

js> Math.pow(12, 2)
144
Comments