I did not understand what Math.pow() was doing? | Sololearn: Learn to code for FREE!
Novo curso! Todo programador deveria aprender IA generativa!
Experimente uma aula grƔtis
+ 1

I did not understand what Math.pow() was doing?

30th Jul 2017, 4:03 AM
Gilad Pinhas
Gilad Pinhas - avatar
3 Respostas
+ 7
TheĀ java.lang.Math.pow(double a, double b) returns the value of the first argument raised to the power of the second argument. Special cases āˆ’ If the second argument is positive or negative zero, then the result is 1.0. If the second argument is 1.0, then the result is the same as the first argument. example: In Math 2^8 = 2x2x2x2x2x2x2x2 =256 In Java Math.pow(2, 8)
30th Jul 2017, 4:06 AM
Art456
Art456 - avatar
+ 6
šŸ˜Š
30th Jul 2017, 4:11 AM
Art456
Art456 - avatar
0
Thanks
30th Jul 2017, 4:08 AM
Gilad Pinhas
Gilad Pinhas - avatar