下列程序中,先声明一个圆类circle和一个桌子类table,另外声明一个圆桌类ro

题型:填空题

问题:

下列程序中,先声明一个圆类circle和一个桌子类table,另外声明一个圆桌类roundtable,它是由 circle和table两个类派生的,要求声明一个圆桌类对象,并输出圆桌的高度,面积和颜色。请填空完成程序
#include<iostream.h>
#include<string.h>
class circle
double radius;
public:
circle(double r)radius=r;
double get_area()return 3.416*radius*radius;

class table
double height;
public:
table(double h)<height=h;
double get_height()return height;

class roundtable:public table,public circle
char *color;
public:
roundtable(double h,double r,char c[]): [10]
color=new char[strlen(c) +1];
[11]

char*get_color()return color;

void main()
roundtable rt(0.8,1.0,“白色”);
cout<<"圆桌的高:"<<rt. get_height()<<end1;
cout<<"圆桌面积:"<<rt.get_area()<<end1;
cout<<"圆桌颜色:"<<n.get color()<<end1;

考点:计算机等级考试C++二级C++笔试
题型:填空题

患者疑诊为结核性腹膜炎,哪项检查阳性率最低

A.腹水腺苷脱氨酶测定
B.腹水涂片找结核杆菌
C.腹水浓缩找结核杆菌
D.腹水结核杆菌培养
E.腹水动物接种

题型:填空题

He is not very confident and always _______ before making a decision.

A.considers

B.hesitates

C.reflects

D.waits

题型:填空题

可作为片剂的润湿剂的是()

A.L-羟丙基纤维素

B.聚乙烯吡咯烷酮溶液

C.聚乙二醇6000

D.乳糖

E.乙醇

题型:填空题

设立全国性商业银行最低注册资本数额为()。

A.1亿元人民币

B.3亿元人民币

C.5亿元人民币

D.10亿元人民币

题型:填空题

冲正交易是指交易局发现账务性业务出现差错,在客户未离开的情况下,对该笔差错交易进行冲正。

更多题库