有如下程序:
#include<iostream>
using namespace std;
class Base{
int x;
public:
Base(int n=0):x(n){cout<<n;)
int getX()const{return x;}
};
class Derived:public Base{
int y;
public:
Derived(int m, int n):y(m,)Base(n){cout<<m;}
Derived(int m):y(m){cout<<m;}
};
int main(){
Derived d1(3),d2(5,7)
return 0;
}
运行时的输出结果是