2082 9

BIT153 ยท 2082 ยท 5 marks

Explain ambiguity problem in multiple inheritance with example. How is it resolved using virtual base class?

Explain ambiguity problem in multiple inheritance with example. How is it resolved using virtual base class? [5]

Object Oriented ProgrammingChapter 6: Inheritance and PolymorphismVirtual base class and ambiguity resolution

When a class inherits from two or more base classes that themselves share a common base class, the derived class ends up with multiple copies of the common base class members. This creates ambiguity because the compiler cannot determine which copy to use. This situation is commonly called the "Di...