You are here : Cmath.hpow

pow() - math.h

The C library function double pow(double x, double y) returns x raised to the power of y i.e. xy.


Syntax

double pow(double x, double y)


Example

#include <stdio.h>
#include <math.h>

int main ()
{
   printf("Value 8.0 ^ 3 = %lf\n", pow(8.0, 3));

   printf("Value 3.05 ^ 1.98 = %lf", pow(3.05, 1.98));
   
   return(0);
}


Output / Return Value

Value 8.0 ^ 3 = 512.000000
Value 3.05 ^ 1.98 = 9.097324


Limitations


Alternatives / See Also


Reference