根据下列程序的运行结果,在空格处填上适当的语句,使其能正确执行。 #include
using namespace std; class Base1{ protected: char str[20]; public: Base1(char *s) { strcpy(str,s); } }; class Base2{ char str[20]; public: Base2(char *s) { strcpy(str,s); } char* get(){ return str; } }; class Derived: Base1{ char str[20]; Base2 obj; public: Derived(char *s1, char *s2, char *s3): Base1(s1),____ { strcpy(str,s3); } void print() { cout<<____<<'\n'<<____<<'\n'<
<<'\n'; } }; int main(void) { Derived test("String A","String B","String C"); test.print(); return 0; } 程序运行结果: String A String B String C