What is the difference between overloading and overriding a
function?

Answer Posted / jitesh singh

OVERLOADING is done in the same class with different
singnature or parameter pass in the function

OVERRIDING is done in different class but the signature or
the parameter is same

Is This Answer Correct ?    12 Yes 3 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is a constructor, constructor overloading in java?

740


What is factor r?

724


Can we create a class inside a class in java?

736


What is a 16 bit word?

761


What is a package in java? List down various advantages of packages.

971


What is difference between path and classpath?

763


When should I use stringbuffer?

762


What is the use of runnable interface?

825


How to make a read-only class in java?

802


What are assembly attributes?

756


What is mutable object and immutable object?

865


Can subclass overriding method declare an exception if parent class method doesn't throw an exception?

735


What is queue in java?

789


What all methods are used to prevent thread execution ?

746


Is singleton a bad practice?

798