Start learning 50% faster. Sign in now
Polymorphism in OOP refers to the ability of a function, method, or object to take on multiple forms. This characteristic allows developers to design interfaces or methods that can perform different tasks based on context. 1. Method Overloading: One of the primary examples of polymorphism is method overloading, where multiple methods share the same name but differ in argument types or counts. 2. Dynamic Behavior: Polymorphism also enables dynamic method invocation at runtime, allowing a subclass to provide a specific implementation for a method defined in its superclass. 3. Extensibility: By allowing objects to process different behaviors through a unified interface, polymorphism enhances code flexibility and scalability. Why Other Options Are Incorrect: • B) A class inheriting properties: This describes inheritance, not polymorphism. • C) Combining multiple objects: This relates to composition, which involves creating a complex object from simpler ones. • D) Restricting access: This refers to encapsulation, which controls data accessibility within a class. • E) Relationships between objects: This describes association or aggregation, not polymorphism.
In which year India became a part of the Mineral Security Partnership (MSP), which is led by the USA?
According World Press Freedom Index 2022 which country is 3rd top most country in the Index?
Sberbank is related to which of the following country?
The famous folk dance of Haryana is?
Buddhism spread in Kashmir during the reign of which king?
Which district of Uttarakhand has the highest fish production (thousand metric ton) in the state as per 2022-23?
Which of the following pairs (Organization - Headquarters) is incorrectly matched?
A) (UNICEF - New York City, U.S.)
B) (UNEP - Nairob...
International Day of Democracy is observed annually on which date?
During which summit was the Quad Cancer Moonshot initiative launched to combat cervical cancer in the Indo-Pacific region?
Where is the headquarters of World Chess Federation (FIDE)?