write a c++ program to do the following to find the perimeter and area of a quadrant
Answers
Answered by
2
#include <iostream>
#define PI 3.14159
using namespace std;
int main()
{
float radius, area, circum;
cout<<" Input the radius(1/2 of diameter) of a circle : ";
cin>>radius;
circum = 2*PI*radius;
area = PI*(radius*radius);
cout<<" The area of the quadrant is : "<< area / 4 << endl;
cout<<" The circumference of the quadrant is : "<< circum / 4 << endl;
cout << endl;
return 0;
}
Similar questions