C program to define power of a function, C/C++ Programming

C program to define power of a function:

Write a program to use power of a function.

void main()

{

int x,y,po=1,i,j;

clrscr();

 

printf("Give x,y\n");

scanf("%d %d",&x,&y);

 

  for(i=1;i<=y;i++)

   {

   po=po*x;

   }

 

printf("%d power %d is %d",x,y,po);

getch();

}

Posted Date: 10/19/2012 3:02:30 AM | Location : United States







Related Discussions:- C program to define power of a function, Assignment Help, Ask Question on C program to define power of a function, Get Answer, Expert's Help, C program to define power of a function Discussions

Write discussion on C program to define power of a function
Your posts are moderated
Related Questions
A name clash happens when a name is described in more than one place. For example, two dissimilar class libraries could give two different classes the similar name. If you try to u

Explain procedural logic A procedure, or function, was explained as a set of specific instructions implemented in sequential manner. The data is kept separate from the procedur

how to create a flowchart? can you help me in my assignment about flowcharting ....

Write a C++ program doing the following: The program reads from the keyboard the numbers of rows and columns of a 2-D array of integers. Then, it allocates this array (let’s name i


A palindrome is a string that reads the same from both the ends. Given a string S convert it to a palindrome by doing character replacement. Your task is to convert S to palindrome

You are to write a C++ program which will compute the gross pay, Social Security Tax, Income Tax and net pay for an employee. The program needs to prompt for and read the employ

Need Squid Web Proxy with ffmpeg to convert flv to h.264 Project Description: We need a squid proxy setup with the modification that will transcode FLV to h.264 in real-time,

Write a recursive function recursiveMin that takes an integer array, a starting subscript and an ending subscript as arguments, and returns the smallest element in the array. The f

minimum of seven number