Computer Science, asked by revantrastogi106, 6 months ago

can someone explain how to use math.pow in java​

Answers

Answered by Anonymous
13

Answer:

The java. lang. Math. pow() is used to calculate a number raise to the power of some other number.

1. If the second parameter is positive or negative zero then the result will be 1.0.

2. If the second parameter is 1.0 then the result will be same as that of the first parameter.

hope it helps

Answered by BrainlyProgrammer
2

Answer:

Math. pow() in java returns with the number raised to power x. Example:-

  \bull\: ( {n}^{x} )

Syntax of Math.pow() in java is very easy...

here is the syntax.

X=Math.pow(n,x);

This statement will return the value of the above given example.

Note:-

  • Math.pow() always the value in double data type
  • To return the value in int data type you can do type casting i.e. (int)(Math.pow(n, x) ;

Learn more about Math function

  • brainly.in/question/31965436?utm_source=android&utm_medium=share&utm_campaign=question
Similar questions