72.7k views
17 votes
Select the correct answer.

Francis has created a new program. However, Francis used some objects from another program to run methods in the current program. What is this feature of OOP called?

A.

code inheritance

B.

code reuse

C.

code flexibility

D.

code regeneration

Reset

User Shawyeok
by
3.5k points

2 Answers

7 votes

Answer:

B. Code Reuse

User Cbuteau
by
5.1k points
11 votes

Answer:

A: Code inheritance

Step-by-step explanation:

In OOP (Object Oriented Programming) languages in Python, when we derive a class from another class for a ranking of classes which share a set of methods and features, we call it inheritance code.

This definition tallies with the one in the question and thus, the correct option is A.

User Vladmir
by
4.4k points