How to translate X to the 25th degree into something that php understands?

I am trying to figure out how code 10 to the 25th degree multiplies a variable. I tried X*(X^25), but this does not return the correct value. If that matters, this is the formula for finding inflation, so the actual formula I'm using is this:

X*(1.01^25)
  • X equal to the estimated amount
  • 1.01 equal to 1% of inflation
  • 25 equal to the number of years, which in this case should be 25.
+4
source share
2 answers

Just use the pow () function:

$x = 10;    
echo pow($x, 25); //(base, exponent)
+3
source

I believe you are looking for the pow team .

pow($number, $exponent)
+1
source

Source: https://habr.com/ru/post/1609547/


All Articles