do a unit test for area circle c++
I hope that you are asking an programme to find out the area of circle in C++ so here is the solution for it.
#include <iostream>
#define PI 3.14159
using namespace std;
int main()
{
//Define radius and area
float radius, area;
//Get the user input for the radius
cout<<" Input the radius";
cin>>radius;
//Computer the area
area = PI*(radius*radius);
cout<<" The area of the circle is : "<< area <<
endl;
cout << endl;
return 0;
}
Kindly vote up if found useful
Get Answers For Free
Most questions answered within 1 hours.