Write a program that calculates circumference and area, C/C++ Programming

Write a program called A1Q3, that reads it the radius of a circle as an integer and prints the circle's diameter, circumference and area.  Use a constant value for pi.  Do all calculations in the output statements.  The output should be in a table format using a tab escape code to align columns.  What happens when the user enters a radius as a real number?

Here is a sample run:

What is the radius: 4 

Diameter:     12.5664

Circumference: 25.1327

Area:      50.2654

Posted Date: 3/8/2013 6:05:08 AM | Location : United States







Related Discussions:- Write a program that calculates circumference and area, Assignment Help, Ask Question on Write a program that calculates circumference and area, Get Answer, Expert's Help, Write a program that calculates circumference and area Discussions

Write discussion on Write a program that calculates circumference and area
Your posts are moderated
Related Questions
What are the benefits of using friend classes? - Friend classes are useful when a class wants to hide features from users which are required only by another, tightly coupled cl

Write a Program for Calculating Value of an Integer? For a clear understanding of recursive function we shall see an illustration for calculating value of an integer. main() {

Within programs we very often want to execute a different section of code, depending upon various conditions within C the If statement is used to achieve this. The If statement con

#include stdio.h   struct  complex   {   float real;   float imag;   };   struct complex complexadd(struct complex,struct  complex);   void main()     {          Date: 26

Write a Program to illustrate Array with Strings? main() { static char name[]="devdas"; int i; i=0; while(name[i]!='\0') { printf("%c",name[i]); i=i+1; } } In the

Requirements: 1.  This assignment as well as other assignments in this class must be finished on Windows operating system. 2.  Zip your program and submit the zip file on ANG

claculate 5% tax >10000 sal

Project Description: Design and prepare software that can navigate a mobile robot using SLAM technique using vision sensor (camera). Skills required are C Programming, Engine

Explain the working of Array with Strings? A string is defined in C language as an array of characters. A null character (‘\0') is automatically added to the end of the charact

Unions A union is also like a structure, except that only single variable in the union is stored in the allocated memory at a time. It is a collection of mutually exclusive var