Answers for "fuction power in c"

C
1

fuction power in c

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

int main()
{
    double base, power, result;

    printf("Enter the base number: ");
    scanf("%lf", &base);

    printf("Enter the power raised: ");
    scanf("%lf",&power);

    result = pow(base,power);

    printf("%.1lf^%.1lf = %.2lf", base, power, result);

    return 0;
}
Posted by: Guest on January-11-2021
2

fuction power in c

int base = 3;
int power = 5;
pow(double(base), double(power));
Posted by: Guest on December-05-2020
3

power func in c

The function pow() is used to calculate the power raised 
to the base value. It takes two arguments. It returns the
power raised to the base value. It is declared in 
“math.h” header file.
Posted by: Guest on December-22-2019

Code answers related to "C"

Browse Popular Code Answers by Language