polymorphism means?

Answer Posted / sujith

The above answer is well explained. In technical terms it
can be explained as same function name with different
signature. Signature means only interms of arguments, and
not for return types. The idea is very simple and is a
feature which make the end user comfortable, and as Swetcha
said, it is finally the compiler will decide, which function
to call when, according to the type of data passed to the
function.
eg. int add(int, int)
double add(double, double)
char add(char, char)

but the following is not possible
int add(int, int)
char add(int, int)

Is This Answer Correct ?    0 Yes 7 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Why is oop useful?

592


What is pointer in oop?

528


Why it is called runtime polymorphism?

570


class CTest { public: void someMethod() { int nCount = 0; cout << "This is some method --> " << nCount; } }; int main() { CTest *pctest; pctest->someMethod(); return 0; } It will executes the someMethod() and displays the value too. how is it possible with our creating memory for the class . i think iam not creating object for the class. Thanks in Advance... Prakash

1685


What are the 4 main oop principles?

667






Can destructor be overloaded?

587


Do you know about multiple inheritance?

632


write a program that takes input in digits and display the result in words from 1 to 1000

1977


What is constructor overloading in oop?

595


What is overloading in oops?

587


What is encapsulation c#?

594


Why is polymorphism needed?

583


c++ program to swap the objects of two different classes

1749


what is the sylabus for priliminaries?

1672


Can we create object of abstract class?

567