#include<stdio.h>
#include<conio.h>
#include<math.h>
#include<string.h>
void main()
{
int x,y;
double power();
clrscr();
printf("Enter value of x : ");
scanf("%d",&x);
printf("Enter value of y : ");
scanf("%d",&y);
printf("%d to power %d is = %f\n",x,y,power(x,y));
getch();
}
double power(x,y)
int x,y;
{
double p;
p=1.0;
if(y>=0)
while(y--)
p*=x;
elsewhile(y++)
p/=x;
return(p);
}