In object-oriented programming, what is the process of creating a new class based on an existing class called?

23 views
  • Aggregation
  • Inheritance (Correct Answer)
  • Composition
  • Encapsulation

Explanation

Answer: b) Inheritance

Explanation: In object-oriented programming, inheritance is the process of creating a new class based on an existing class. The new class inherits all the properties and methods of the existing class and can add new functionality or override existing behavior.

Comments (0)

No comments yet. Be the first to comment!

Want to practice more?

Explore thousands of MCQs across every exam category on Exams Nepal.

Find More MCQs