What is the Difference between Overriding and overloading?

Answer Posted / prachee

overloading has same method but different types of
parameters, number of parameters.

overloading does not take return type to differentiate
overloaded method.

ex:
int add(int a, int b)
int add(float a , float b)
are overloaded methods

overriding comes with inheritance concept.
here parent and child both contains the same method. and
when execution takes place; child's method is called.

Is This Answer Correct ?    124 Yes 14 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Can you please explain the difference between dispose and finalize()?

508


Explain the services provided by common language infrastructure.

726


What is meant by jagged arrays?

584


How to connect crystal report in vb.net ?

581


What is the top .net class that everything is derived from?

620






List the different types of assembly?

550


What is code access security?

691


Explain about jagged arrarys ?

517


How to send xml file on server using http protocol?

544


How do you call a stored procedure in Visual Basic?

587


Explain about globalization?

504


Explain clr?

577


What do you understand by vb.net?

617


what is commom language runtime?

559


What is the significance of delegates. Where should they be used?

520