Question: Write a C program to declare three functions, to compute 1) Volume of Cone using call by value, 2) Volume of Cylinder using call by


Write a C program to declare three functions, to compute 1) Volume of Cone using call by value, 2) Volume of Cylinder using call by reference, 3) Largest number in an array using call by reference. Below are the function prototypes: double callByValueCone (double, double) void callByReferenceCylinder (double, double, double*) void callByReferenceLargest(int*, int*) Follow the steps below to design your program: 1. Read the height and radius of a cone. 2. Read 5 integer numbers into an array. . Call function callByValueCone (), passing height and radius of the base of a cone, receiving the volume of the cone, and printing the volume. Call function callByReferenceCylinder(), passing height and radius of the base of a cylinder, receiving the volume of the cylinder, and printing the volume. 4. 5. Call function callByReferenceLargest(), sending the array of 5 numbers, receiving the largest number, and printing the number
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
