Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...


Difference between overloading and overridding?

Answers were Sorted based on User's Feedback



Difference between overloading and overridding?..

Answer / tulasi

Overloading is the concept where there are many methods
with the same name in a class but the arguments passed
differ.Consider the example of method called
addition.Addition can be between integers,floating point
numbers etc., so same name addition is used for the various
methods of class but the parameters passed differ, it may
be integer or floating point.When the jvm checks for the
methods, the method is choosen depending upon the argument
passed.

Overriding is the concept where the method name is
same,arguments passed are also same and the return type is
also same.but the method implemented depends upon where its
defined and called

Is This Answer Correct ?    13 Yes 1 No

Difference between overloading and overridding?..

Answer / ravikiran

compile time polymorhism is named as overloading,and takes
place in the same class.Should have same method name but
must have different argument list.
Runtime polymorphism is named as overriding,and takes place
in diferent classes.Must have the same signature and
argument list including the order defined in the super
class.

Is This Answer Correct ?    10 Yes 1 No

Difference between overloading and overridding?..

Answer / guest

overriding means same method same arguments and same retun
type
overloading means same but with different arguments

Is This Answer Correct ?    8 Yes 1 No

Difference between overloading and overridding?..

Answer / j.winston britto

Overloading means,
More than one method have same name and every one
differ in no. of arguments,type of arguments in a class.

Overridding means,
methods having same name and type in different
classes.In this we can use "super" key word

Is This Answer Correct ?    4 Yes 1 No

Post New Answer

More Core Java Interview Questions

What is the entry point in Java, and how is it written?

2 Answers  


what do you understand by synchronization? Or what is synchronization and why is it important? Or describe synchronization in respect to multithreading? Or what is synchronization? : Java thread

0 Answers  


What are daemon Threads in java?

0 Answers   Impetus,


23. Storage space in java is of the form Stack Queue Heap List 24. What is java code embedded in a web page known as Applets Servlets scriptlets snippets 25. Which of the following attributes are compulsory with an <applet> tag?. code,height & width. 26. What does 'CODEBASE' in an applet tag specify?. Files absolute path.

0 Answers   TCS,


In Java, what are this() and super(), and where are you required to use them?

2 Answers  


Why deletion in linkedlist is fast than arraylist?

0 Answers  


What is remote method invocation (rmi)?

0 Answers  


What are anonymous inner classes?

0 Answers  


What is downcasting?

0 Answers  


What is a Java package and how is it used?

2 Answers  


In how many ways we can create threads in java?

0 Answers  


What does main method?

0 Answers  


Categories