#include <iostream.h>
const float PI=(float)3.14159;
class Circle
{
public:
Circle(float r);
float Area();
private:
float radius;
};
Circle::Circle(float r){radius=r;}
float Circle::Area()
{
return PI * radius * radius;
}
void main()
{
float radius;
float c;
cin>>radius;
Circle Pool(radius);
cout<<”the result is “<<Area()<<endl;
}
这是C++程序
请各位看看哪里出错了
>> 本文固定链接: http://www.vcgood.com/archives/2809