Here's a C program to find power of a number using pow() Function. This pow() function is not available to use by default, you first have to include the Math.H Header File to use this function.

# include <stdio.h> # include <conio.h> # include <math.h> void main() { int x, n, power; clrscr() ; printf("Enter the value of x : ") ; scanf("%d", &x) ; printf("\nEnter the value of n : ") ; scanf("%d", &n) ; power = pow(x, n); //This will calculate x ^ n printf("\nThe power of %d^%d is : %d", x, n, power) ; getch() ; }

**Output of above program is**

Enter the value of x : 2

Enter the value of n : 4

The power of 2^4 is : 16

Also look at:Program to calculate power without using pow() function. This program uses while loop to calculate the power. C Program to Find Power of a Number using While Loop

What is double?

It is a Double precision floating point number of size 8 bytes. Being larger in size than FLOAT, DOUBLE can store floating point values with great level of precision.