5. write a program to calculate the area of circle. The equation for determining the area of acircle is area 3.1416 radius radius, Assume that the circle has a 5 inches 6. Write a program to calculate the volume of a pool. The equation for determining the volume is: volume- length width depth. Assume that the pool has a length of 25 feet,a width of 10 feet, and a depth of 6 feet. e 7. Write a program to convert temperature in degrees Fahrenheit to degrees Celsius. The equation for this conversion is Celsius- 5.0/9.0 (Fahrenheit -32.00. Have your program convert and displays the Celsius temperature corresponding to 98.6 degrees Fahrenheit
Expert Answer
#include<iostream>
using namespace std;
int main()
{
float radius,area;
cout<< “nEnter radius of circle : “;
cin>>radius;
area = 3.14*radius*radius;
cout<<“Area of circle : “<<area;
return 0;
}
6) C++ program to calculate volume of pool:
#include<stdio.h>
int main()
{
int len , wid,dep, V;
cout<<“Enter the length of the swimming pool: “<<endl;
cin>>len;
cout<<“Enter the width of the swimming pool: “<<endl;
cin<<wid;
cin<<“Enter the depth of the swimming pool: “<<endl;
cin<<dep;
V = len * wid * dep;
cout<<“Volume is “<<V;
return 0;
}
7. C++ program to convert tempurature from faurenheit to celsius:
#include<iostream.h>
#include<conio.h>
void main()
{
float celsius, fahrenheit;
clrscr();
cout<<“Enter temp. in Fahrenheit: “;
cin>>fahrenheit;
celsius = (fahrenheit – 32) * 5/9;
cout<<“Temp. in Celsius: “<<celsius;
getch();
}
9)
#include<stdio.h>
int main()
{
int feet,mile=2.36;
feet = 5280*mile;
cout<<“distance in feets: “<<feet;
}