0
What is the Errors ?
#include <iostream> using namespace std; class Base { int m; public: Base(int mValue){ m = mValue; cout<<"Constructing base"; } }; class Derived: public Base {double n; public: Derived(double nValue) { n =nValue; cout<<"Constructing derived"; } }; int main(){ Base b1; Base b2(3.0); Derived d1 Derived d2(4.0); return 0; }
0 Respuestas