匿名用户
1级
2018-10-21 回答
#include #include using namespace std; #define PI 3.1415 class circle{public: void information(double & a) { cout<>a; } }; class sphere:public circle{public: void first(double a) { double v1; double s1; s1=4*PI*a*a; //第一二处错误 v1=(PI*a*a*a*4)/3 ; cout<>h; s2=2*2*PI*a*a+2*PI*a*h; v2=2*PI*a*a*h; cout<>l; s2=2*PI*a*a+PI*a*l; v2=2*PI*a*a*l/3; cout<>chose; circle bason; bason.information(a); cout<