若有以下程序:
#include <iostream>
using namespace std;
class Base
private:
int a,b;
public:
Base(int x, int y)
a=x;
b=y;
void show( )
cout<<a<<", "<<b<<end1;
;
class Derive : public Base
private:
int c, d;
public:
Derive(int x,int y, int z,int m):Base(x,y)
c=z;
d=m;
void show( )
cout<<c<<", "<<d<<end1;
;
int main ( )
Base b(50,50),*pb;
Derive d(10,20,30, 40);
pb=&d;
pb->show ( );
return 0;
招待程序后的输出结果是( )。
题库:计算机等级考试
类型:最佳选择题
时间:2017-07-03 15:02:38
免费下载:《单项选择》Word试卷
若有以下程序:
#include <iostream>
using namespace std;
class Base
private:
int a,b;
public:
Base(int x, int y)
a=x;
b=y;
void show( )
cout<<a<<", "<<b<<end1;
;
class Derive : public Base
private:
int c, d;
public:
Derive(int x,int y, int z,int m):Base(x,y)
c=z;
d=m;
void show( )
cout<<c<<", "<<d<<end1;
;
int main ( )
Base b(50,50),*pb;
Derive d(10,20,30, 40);
pb=&d;
pb->show ( );
return 0;
招待程序后的输出结果是( )。
A.10,20
B.30,40
C.20,30
D.50,50
本题关键词:程序,有序镜检,大腿以下或膝以下肌肉瘫痪,工程施工程序,复苏程序,工作程序,建设程序,程序变更,程序冲突,点火程序;