What happens when you attempt to compile and run the following code? #include
class A { public: int age; A () { age=5; };
};
class B : private A { string name; public: B () { name=”Bob”; }; void Print() { cout << name << age;
}
};
int main () { B b,*ob; ob = &b; ob?>age = 10; ob?>Print(); return 0; }
A. It prints: Bob55
B. It prints: Bob1
C. It prints: 10
D. Compilation error