In C++, can a class inherit from multiple parents?
Anonymous
Yes, C++ supports multiple inheritance, meaning that a child class can inherit methods & attributes from multiple "unrelated" classes. Multiple inheritance is often misused, introducing unnecessary complexity & ambiguity, which helps explain why it is not a standard feature in OOP languages. For example, Java only supports single inheritance.
Check out your Company Bowl for anonymous work chats.