Can an object of an abstract class be created directly in C++?

Options

  • A. Yes, in every situation
  • B. Yes, only when it has a constructor
  • C. No, an abstract class cannot be instantiated directly
  • D. More than one of the above
  • E. None of the above

Correct Answer (Detailed Explanation is Below)

C. No, an abstract class cannot be instantiated directly

Detailed Explanation

Correct Answer: Option C

Explanation:
An abstract class cannot be instantiated directly because it has at least one pure virtual function that has not been implemented by the class. It can, however, be used as a base class for a concrete derived class.