c program to multiply exponent and base

c program to multiply exponent and base 



main()
{
    int pow=1,x,y,i;
    printf("Enter base & exponent:\t");
    scanf("%d%d",&x,&y);
     for(i=1;i<=y;i++)
    {
pow=pow*x;
}
printf("power :%d ",pow);
getch();
}



No comments:

Post a Comment