🌐
Microsoft Learn
learn.microsoft.com › en-us › dotnet › api › system.math.pow
Math.Pow(Double, Double) Method (System) | Microsoft Learn
The following example uses the ... 0 to 32. int value = 2; for (int power = 0; power <= 32; power++) Console.WriteLine($"{value}^{power} = {(long)Math.Pow(value, power):N0} (0x{(long)Math.Pow(value, power):X})"); // The example ...
🌐
GeeksforGeeks
geeksforgeeks.org › java › math-pow-method-in-java-with-example
Math pow() Method in Java with Example - GeeksforGeeks
March 28, 2025 - Explanation: In the above code, we have declared two variables a (base) and b (exponent) and then the program calculates the result of raising the base (a) to the power of the exponent (b) using the Math.pow() method and prints the result.
🌐
MDN Web Docs
developer.mozilla.org › en-US › docs › Web › JavaScript › Reference › Global_Objects › Math › pow
Math.pow() - JavaScript | MDN
console.log(Math.pow(7, 3)); // Expected output: 343 console.log(Math.pow(4, 0.5)); // Expected output: 2 console.log(Math.pow(7, -2)); // Expected output: 0.02040816326530612 // (1/49) console.log(Math.pow(-7, 0.5)); // Expected output: NaN
🌐
W3Schools
w3schools.com › python › ref_math_pow.asp
Python math.pow() Method
Python Examples Python Compiler ... math Library import math #Return the value of 9 raised to the power of 3 print(math.pow(9, 3)) Try it Yourself »...
🌐
W3Schools
w3schools.com › jsref › jsref_pow.asp
JavaScript Math pow() Method
The Math.pow() method returns the value of x to the power of y (xy).
🌐
Programiz
programiz.com › java-programming › library › math › pow
Java Math pow()
System.out.println(Math.pow(-num1, -num2)); // 0.008 } } In the above example, we have used the Math.pow() with positive numbers, negative numbers, zero, and infinity.
🌐
Codecademy
codecademy.com › docs › java › math methods › .pow()
Java | Math Methods | .pow() | Codecademy
June 23, 2025 - The method returns a double value representing the result of base raised to the power of exponent. Special cases include returning NaN for invalid operations, Infinity for overflow conditions, and specific handling for zero and one values. This example demonstrates the fundamental usage of the Math...
🌐
Programiz
programiz.com › javascript › library › math › pow
JavaScript Math.pow() (with Examples)
Math.pow("6", "2") - converts the numeric string to numbers and computes the power
🌐
Codecademy
codecademy.com › docs › c# › math functions › .pow()
C# (C Sharp) | Math Functions | .Pow() | Codecademy
April 29, 2023 - The following example is runnable and uses the Math.Pow() method to return a double type value of 2 raised to the power of 10:
Find elsewhere
🌐
Tutorialspoint
tutorialspoint.com › home › java/lang › java math.pow() method
Java Math.pow() Method
September 1, 2008 - The Java Math pow(double a, double b) returns the value of the first argument raised to the power of the second argument.
🌐
Javatpoint
javatpoint.com › java-math-pow-method
Math.pow()
Math.pow() Math.signum() Math.ceil() Math.copySign() Math.nextAfter() Math.nextUp() Math.nextDown() Math.floor() Math.floorDiv() Math.random() Math.rint() Math.hypot() Math.ulp() Math.getExponent() Math.IEEEremainder() Math.addExact() Math.subtractExact() Math.multiplyExact() Math.incrementExact() Math.decrementExact() Math.negateExact() Math.toIntExact() Math.log() Math.log10() Math.log1p() Math.exp() Math.expm1() Math.sin() Math.cos() Math.tan() Math.asin() Math.acos() Math.atan() Math.sinh() Math.cosh() Math.tanh() Math.toDegrees ·
🌐
Baeldung
baeldung.com › home › java › java numbers › using math.pow in java
Using Math.pow in Java | Baeldung
January 8, 2024 - The method raises a to the power of b and returns the result as double. In other words, a is multiplied by itself b times. ... The output will be 8. Please note that the int casting in the above example is required if we want to have an Integer ...
🌐
Tutorialspoint
tutorialspoint.com › python › number_pow.htm
Python math.pow() Method
Following is the syntax of Python math.pow() method − ... This method returns the value of xy. In the following example, we are using math.pow() with integers (2 as the base and 3 as the exponent).
🌐
CodeGym
codegym.cc › java blog › java math › math pow() method in java
Math.pow() Method in Java
December 5, 2024 - Let’s consider one instance where this 3rd situation can happen. import java.lang.Math; public class MyClass{ public static void main(String []args){ double base = 5; double exponent = Double.NaN; double answer = Math.pow(base, exponent); ...
🌐
Medium
medium.com › @AlexanderObregon › javas-math-pow-method-explained-7c0f746ad420
Understanding Java's Math.pow() Method | Medium
July 16, 2024 - The base is the number that is being multiplied, and the exponent indicates how many times the base is multiplied by itself. For example, in the expression “2 raised to the power of 3”, 2 is the base, and 3 is the exponent.
🌐
Educative
educative.io › answers › how-to-use-the-mathpow-method-in-java
How to use the Math.pow() method in Java
The pow() method is a part of java.lang.Math class, you need to import this class in your code to use the function.
🌐
Vultr Docs
docs.vultr.com › javascript › standard-library › Math › pow
JavaScript Math pow() - Calculate Power Value | Vultr Docs
December 2, 2024 - Use Math.pow() for calculating area or volume where exponents are involved. Example: Calculate the volume of a cube with side length s.
🌐
Cppreference
cppreference.com › w › c › numeric › math › pow.html
pow, powf, powl - cppreference.com
Although pow cannot be used to ... STDC FENV_ACCESS ON int main(void) { // typical usage printf("pow(2, 10) = %f\n", pow(2, 10)); printf("pow(2, 0.5) = %f\n", pow(2, 0.5)); printf("pow(-2, -3) = %f\n", pow(-2, -3)); // special values printf("pow(-1, NAN) = %f\n", pow(-1, NAN)); ...
🌐
Oracle
docs.oracle.com › cd › B40099_02 › books › eScript › eScript_JSReference232.html
Bookshelf v8.0: Math.pow() Method
Siebel eScript Language Reference > Siebel eScript Commands > Math Objects > · This function returns the value of its first parameter raised to the power of its second parameter