Calculate the area and circumference of a circle , C/C++ Programming

Write a program which incorporates a function named compute and which is used to calculate the area and circumference of a circle. Use the main function for inputs and outputs.

#include

//function prototype

void ComputeCircle(int r,double &,double &);

int main()

{

int radius;

double area, circ;

cout<<"Enter the radius of your circle"<>radius;

ComputeCircle  (radius,area,circ);

cout<<"The area of the circle is:"<

cout<<"The Circumference of the circle is:"<

}

void ComputeCircle(int r, double & A, double & C) 

Posted Date: 8/21/2012 11:26:07 AM | Location : United States







Related Discussions:- Calculate the area and circumference of a circle , Assignment Help, Ask Question on Calculate the area and circumference of a circle , Get Answer, Expert's Help, Calculate the area and circumference of a circle Discussions

Write discussion on Calculate the area and circumference of a circle
Your posts are moderated
Related Questions
how can i write reverse digit function like writing 1234 and printing 4321

A cl a s s c a n b e d e f i n e d i n s i d e a b l o c k o r f u n c t i o n.   T h i s t yp e cla s s i s known

A: They present a degree of freedom in the interface design options. Member functions & friend functions are equally privileged (100% vested). The major difference is that a fri


Objective:  Construct a C program that controls the LCD display, and is capable of displaying strings.  Add functions to the C program that allows more control over the display.

Is it possible to pass an entire structure to functions? Yes, it's possible to pass an entire structure to a function in a call by method style. Some programmers prefer to decl


Reference Types The symbol "&" is interpreted as an address operator as well as AND operator. This operator is also used to declare a "reference variable". A reference is refer

what is a string?

Q: How can Define an Array? An Array is defined in much the alike manner as ordinary variables except that every array name must be accompanied by a size specification (that is