What are the different forms of polymorphism??
Answer Posted / mms zubeir
Though there are many answers which are all true to some
extent, I would like to conclude all these into two broad
categories:
1. Ad-hoc polymorphism
2. Parametric polymorphism
As the meaning of the names themselves suggests their usage.
If the range of actual types that can be used is finite
and the combinations must be specified individually prior
to use, it is called Ad-hoc polymorphism.
If all code is written without mention of any specific type
and thus can be used transparently with any number of new
types, it is called parametric polymorphism.
| Is This Answer Correct ? | 5 Yes | 3 No |
Post New Answer View All Answers
What does and I oop mean?
What are functions in oop?
What is class encapsulation?
write a code for this:trailer recordId contains a value other than 99, then the file must error with the reason ‘Invalid RECORD_ID’(User Defined Exception).
What is a superclass in oop?
What is overriding in oops?
Why is there no multiple inheritance?
What is an example of genetic polymorphism?
Write a java applet that computes and displays the squares of values between 25 and 1 inclusive and displays them in a TextArea box
What exactly is polymorphism?
Write a program to reverse a string using recursive function?
String = "C++ is an object oriented programming language.An imp feature of oops is classes and objects".Write a pgm to count the repeated words from this scenario?
What is ambiguity in inheritance?
Give an example where we have to specifically use C programming language and C++ programming language cannot be used?
What is the purpose of polymorphism?