Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Computer Science II assignment #5 Write a C program named assignment04.cpp that will 1. ask for and read in a float for a radius 2.

Computer Science II assignment #5 Write a C program named assignment04.cpp that will 1. ask for and read in a float for a radius 2. ask for and read in a float for the height 3. each of the following functions will calculate some property of a shape (area, volume, circumference, etc) 4. The functions will accept one or two parameters (radius and/or height) and return the proper calculation. 5. There is no input/output (cin or cout) in the function just the calculation 6. write the following functions a. float areaCircle(float radius) where the area of a circle is calculated by area = PI * radius * radius b. float circumCircle(float radius) where the circumference of a circle is calculated by circumference = PI * radius * 2 c. float areaCylinder(float radius, float height) where the area of a cylinder is calculated by area = 2 * PI * radius * radius + height * PI * radius * 2 d. float volumeCylinder(float radius, float height) where the volume of a cylinder is calculated by volume = PI * radius * radius * height e. float volumeCone(float radius, float height) where the area of a cylinder is calculated by volume = (1 / 3) * (PI * radius * radius * height)

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Icdt 88 2nd International Conference On Database Theory Bruges Belgium August 31 September 2 1988 Proceedings Lncs 326

Authors: Marc Gyssens ,Jan Paredaens ,Dirk Van Gucht

1st Edition

3540501711, 978-3540501718

More Books

Students also viewed these Databases questions

Question

Define capital structure.

Answered: 1 week ago

Question

List out some inventory management techniques.

Answered: 1 week ago

Question

3. Evaluate your listeners and tailor your speech to them

Answered: 1 week ago