Management Information System (MIS) Practice Exam

Disable ads (and more) with a membership for a one time $2.99 payment

Prepare for the Management Information System Test. Boost your knowledge with flashcards and multiple choice questions, each question includes hints and explanations. Be exam-ready today!

Each practice test/flash card set has 50 randomly selected questions from a bank of over 500. You'll get a new set of questions each time!

Practice this question and more.


Which of the following programming concepts allows for two or more different classes to share the same method name?

  1. A) Inheritance

  2. B) Encapsulation

  3. C) Polymorphism

  4. D) Abstraction

The correct answer is: C) Polymorphism

Polymorphism is the programming concept that enables two or more different classes to share the same method name, allowing for methods to perform different tasks based on the object that calls them. This concept is particularly powerful in object-oriented programming as it facilitates code reusability and flexibility. When polymorphism is implemented, particularly through method overriding, a subclass can provide a specific implementation of a method that is already defined in its parent class. As a result, regardless of the specific class type, objects can be treated as instances of their parent class. This means that when a method is called on an object, the correct version of the method (based on the actual object type) is executed, thus achieving dynamic method dispatch. In contrast, inheritance allows one class to inherit properties and methods from another but does not inherently involve sharing method names among different classes. Encapsulation focuses on bundling the data and the methods that operate on the data, ensuring that the internal representation of an object is hidden from the outside. Abstraction, on the other hand, deals with hiding complex reality while exposing only the necessary parts, but does not directly relate to method name sharing among classes.