Question 102Asked in BPSC TRE 2.0 (2023) Computer Science Class 11-12

Which concept of C++ is used to reuse the written code?

  1. APolymorphism
  2. BInheritance
  3. CEncapsulation
  4. DMore than one of the above
  5. ENone of the above
Show answerHide answer

Correct answer: (B) Inheritance

Explanation

Inheritance lets a derived class reuse the data and functions of an existing base class without rewriting them.

From BPSC TRE 2.0 (2023) Computer Science Class 11-12 — Previous Year Paper

This is question 102 of BPSC TRE 2.0 (2023) Computer Science Class 11-12 — Previous Year Paper. See all questions of this paper with answers, or attempt the paper as a timed online test to get your score and all-India rank.