what is overloading in java?

Answer Posted / ak

Overloading is when the same method or operator can be used
on many different types of data.

For instance the + sign is used to add ints as well as
concatenate strings. The plus sign behaves differently
depending on the type of its arguments. Therefore the plus
sign is inherently overloaded.

Methods can be overloaded as well..same method with
different parameters is said to be method overloading.----
we can perform the similar operation in different ways for
different parameters.

Constructors can be overloaded as well...Overloaded
constructors provide multiple ways to initialize a new object

Is This Answer Correct ?    69 Yes 12 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is the use of predicate in java 8?

689


What are the main uses of the super keyword?

755


Is it possible to override private or static method in java?

759


Explain about wait() method?

781


What is bom encoding?

775


What is string and its types?

850


Why do we need wrapper classes?

805


What are the 4 types of research methods?

697


What is the replace tool?

772


When do we use synchronized methods in java?

790


What is arrays fill in java?

749


What is functional interface in java?

766


What does escaping a character mean?

724


What exactly is a .class file?

813


What are the restrictions that are applied to the java static methods?

761