Which code, inserted at line 18, generates the output "AB"
#include
using namespace std;
class A
{
public:
void Print(){ cout<< "A";}
void Print2(){ cout<< "a";}
};
class B:public A
{
public:
void Print(){ cout<< "B";}
void Print2(){ cout<< "b";}
};
int main()
{
B ob2;
//insert code here
ob2.Print();
}
Currently there are no comments in this discussion, be the first to comment!