MCQs > IT & Programming > Symbian C++ > Suppose you have 2 classes namely, Person and Footballer, as follows: class Person { virtual void func(void) { ; } }; class Athlete : public Person { /* . . . */ }; and suppose 2 pointers are defined as follows: Person *Joy = new Person; Person *Max = new Athlete; What will be the value of the variable 'a', if the following dynamic_cast statement is executed? a = dynamic_cast(Joy);

Symbian C++ MCQs

Suppose you have 2 classes namely, Person and Footballer, as follows:
class Person { virtual void func(void) { ; } };
class Athlete : public Person { /* . . . */ };
and suppose 2 pointers are defined as follows:
Person *Joy = new Person;
Person *Max = new Athlete;
What will be the value of the variable "a", if the following dynamic_cast statement is executed?
a = dynamic_cast(Joy);

Answer

Correct Answer: 0

Explanation:

Note: This Question is unanswered, help us to find answer for this one

Symbian C++ Skill Assessment

Overall Skill Level-Poor

Your Skill Level: Poor

Retake Quizzes to improve it

search

Symbian C++ Skill Assessment

Overall Skill Level-Poor

Your Skill Level: Poor

Retake Quizzes to improve it